Posts

Showing posts from June, 2011

ruby on rails - Add stylesheet link from a gem -

I am working on a gem that will accept common CSS styles. The fonts were embedded in them and they were added to the asset pipeline, but I am trying to switch to Google font. What do I do & lt; Link href = 'http to add: //fonts.googleapis.com/a ?? | 'Rel =' stylesheet 'type =' text / css' & gt; tags to & lt; Head & gt; Automatically, adding gem will add this additional stylesheet. Is it possible, or users of gem manually add it? You have to make some helpful functions and keep it in your application layout. It can not be added automatically

javascript - parse http response content string -

I am working with JavaScript in the meteor and I request an HTTP.get request for an API and a response I get res = {..., content: "access_token = 4h378fi243h085giouf245 and end = 5180430", data = zero} . As you can see, res.content is a string but it actually reflects a good JSON object {access_token: 4h378fi243h085giouf245, expired: 5180430} . Is there a meteor or javascript package / easy solution to convert that string into that object? (I've seen some manual string parsing solutions but it seems to be hacking, and it seems that some meteors or javascript will provide for you.) Edit: JSON.parse Res.content is really the first attempt, but it gives me 'unexpected token', I'm guessing 'access_token'. Why would not this happen? This is not really JSON, this is the URL criteria string. var results = {}; Res.content.split ("& amp;") forEach (function) {var item = part.split ("="); Results [item [0]] = decodeu...

Accessing Ajax Parameters in Java -

मान लें कि निम्न http अनुरोध भेजा जाता है: http: //example.com# ! & Amp; parm1 = 123 मैं Servlet में जावा में param1 के लिए मान का उपयोग करना चाहता हूं। मैं यह कैसे कर सकता हूँ? मुझे पता है कि #! अजाक्स मापदंडों के लिए उपयोग किया जाता है, लेकिन इस मामले में अनुरोध जावा Servlet पर जाता है, और Servlet param1 के लिए मान को प्राप्त करने में सक्षम होना चाहिए। नोट: अधिकांश लोग इस से उलझन में हैं द! हैशबैंग में, #! में, हैश (#) के फ़ंक्शन को रद्द कर देता है। इस प्रकार परम 1 भेजा जाता है, लेकिन मेरी समस्या यह एक जावा सर्वलेट में प्रवेश कर रही है धन्यवाद, साइरस # के बाद यूआरएल का हिस्सा आवश्यक रूप से एजेएक्स से संबंधित नहीं है। यह दस्तावेज़ हैशोड है या आधुनिक AJAX पैटर्न इस पहचानकर्ता को पैरामीटर और अन्य सूचनाओं को संग्रहीत करने के लिए एक स्थान के रूप में उपयोग करते हैं। महत्वपूर्ण तथ्य यह है कि यह कभी भी सर्वर पर नहीं भेजा जाता है सर्वर टुकड़ों के साथ यूआरएल भेज सकता है, लेकिन क्लाइंट सर्वर को इस टुकड़े को कभी नहीं भेजता है। आपको यूआरएल को पार्स करने और # के बाद मान ...

github - Unable to push to Git Repository after adding a branch -

I have a git repository with approximately 4 branches, they GitHub Are put on. I have recently created a new branch named "Demo 2 Full" since its creation, I am unable to push any eastern branch named "Bugfixes". The new branch "demo2Full" has been created on the butt, which is similar to "bugfix". Git Remote Demo2Full git @ github-user: add user / project_demo2Full.git On the local machine: git branch demo 2 full & amp; GIT checkout Demo 2 full . After this I switched "Bugfixes" with GIT checkout bugfix without issue. Now, when I do: git push origin bugfixes , I get the following error: Error: The repository was not found. Fatal: Could not be read from the remote repository Please ensure that you have the right access rights and the repository is present. I have gone through several links, the ssh part works, and I have to remove the remote with git remote -v .git / config and found that there...

java - Suppress default double-click event in SWT.CHECK Table -

मैं SWT तालिका का उपयोग कर रहा हूँ SWT.CHECK और SWT.FULL_SELECTION । मैंने एक आउटपुट समूह को भरने के लिए माउसलेस्टनर जोड़ा, जब कोई उपयोगकर्ता तालिका पंक्ति को डबल-क्लिक करता है हालांकि, एक डबल-क्लिक पंक्ति के चेकबॉक्स को भी टॉगल करेगा। हालांकि मुझे लगता है कि यह लक्ष्य प्लेटफॉर्म (विंडोज) के व्यवहार का इरादा है, मैं चेकबॉक्स को टॉगलिंग से रोकना चाहता हूं। क्या यह संभव है नहीं चेकबॉक्स को डबल- क्लिक करें? मुझे पता चल गया है कि तालिका कार्यान्वयन मैं एक चयनलेस्टनर को जोड़ रहा था जो चेकबॉक्स को टॉगल करता था जब मैंने इसे हटा दिया, तो सबकुछ अपेक्षित काम किया: श्रोता [] श्रोताओं = table.getListeners (SWT.Selection); अगर (listeners.length & gt; 0) {टाइप किया गया लिस्टनर टाइप लिस्टनर = (टाइप्ल्ड लिस्टनर) श्रोताओं [0]; चयनःलिस्टर चयनलाइज़र = (SelectionListener) typedListener.getEventListener (); table.removeSelectionListener (selectionListener); } एक साफ समाधान नहीं है, लेकिन जब से मुझे पता है कि उस समय ऑब्जेक्ट में केवल एक चयन लिस्टनर है, ऐसा लगता है कि इसे इस तरीके...

javascript - PureScript does not compose `trace` and `show` -

तो निम्न कार्य करता है मुख्य = ट्रेस $ $ $ दिखाने लेकिन यह नहीं है मुख्य = do (ट्रेस। शो) 5 में psci का प्रकार है forall r Prim.String - & gt; Control.Monad.Eff.Eff (trace :: debug.Trace.Trace | r) प्रस्तावना। यूनिट और शो का प्रकार है forall ए। (प्रील्यू। एक देखें) = & gt; ए - & gt; Prim.String क्योंकि शो का रिटर्न वैल्यू Prim.String है और पहले इनपुट में ट्रेस है Prim.String उन्हें चाहिए कंपोज़ योग्य हो इसके आगे यह पता चला है कि ट्रेस $ शो प्रकार जांच से गुजरता है लेकिन इसके बजाय मुझे यह त्रुटि मिलती है: त्रुटि 1 लाइन में, कॉलम 10: घोषणा में त्रुटि यह Prim.Function Prim.String के साथ Prim.Object को एकजुट नहीं कर सकता। मुझे यहाँ क्या याद आ रही है? अभी मेरा मानसिक मॉडल यह है कि हाससेल में ट्रेस बहुत ही putStrLn जैसा है, और यह निश्चित रूप से शो से बना हो सकता है। (putStrLn। Show) 5 काम करता है। ट्रेस और शो के रचना परिणाम का अपेक्षित प्रकार: एक आर (प्रील्यू। एक देखें) = & gt; ए - & gt; Control.Monad.Eff.Eff (trace :: ...

java - Jersey Service with Object as parameter -

मैं कुछ जर्सी सेवाएं निम्नानुसार करता हूं @GET @ path ("/ GetUsers ") @ उत्पाद (मीडियाटाइप। एपीआईएलआईसीएशन_जेएसओएन +"; वर्णसेट = यूटीएफ -8 ") सार्वजनिक सूची & amp;; कैंपानिया & gt; FindUsers (@QueryParam ("उपयोगकर्ता नाम") स्ट्रिंग उपयोगकर्ता) {सूची & lt; उपयोगकर्ता & gt; प्रयोक्ता = यूजरबीएल.जेटयूएसर्स (); वापसी उपयोगकर्ता; } मेरी समस्या यह है कि इस पद्धति को 10 पैरामीटर प्राप्त करना चाहिए, इसलिए मुझे केवल एक पैरामीटर पसंद करना होगा: GetUsersFilter जिसमें 10 मापदंड हैं। एकमात्र तरीका मुझे पता है कि, @GET से @ POST में बदल रहा है, लेकिन, यह सेवाएं एक जीईटी होनी चाहिए। एक और तरीका है? आप कई क्वेरी पैरामीटर (और अन्य सामान) को बंडल करने के लिए एनोटेशन का उपयोग कर सकते हैं एक एकल जावा ऑब्जेक्ट: // पैरामीटर ऑब्जेक्ट जो सभी मापदंडों को पब्लिक क्लास यूज्यूएक्लापमेंट्स {@QueryParam ("userName") निजी स्ट्रिंग यूजर; @क्व्यापरम ("परम 2") निजी स्ट्रिंग परम 2; ... // getters आदि} फिर अपने जेएक्स-आरएस संसाधन विध...

angular ngmodel - AngularJs Directive two way binding: How to preserve reference? -

I have a directive in which there is two types of bond with one attribute. I want to reassign the attribute in the link function. However, this reference breaks. What is the correct way to do this? & lt; Div ng-app = "zippy module" & gt; & Lt; Div ng-controller = "ctrl3" & gt; Title: & lt; Input ng-model = "title" & gt; & Lt; Div class = "zippy" zippy-title = "obj" & gt; {{Obj.a}} & lt; / Div & gt; & Lt; / Div & gt; & Lt; / Div & gt; JavaScript function Ctrl3 ($ scope) {$ scope.obj = {a: "a", b: "b"}; } {Angular Module ('zippyModule', []). Directive ('zippy', function () {return: {title: '= zippyTitle'}, link: function (region, element, attrs) {title = A: "C", B: "D"}}}}; }); Try it out: HTML & lt; Div ng-app = "zippy module" & gt; & Lt; Div ng-controller = "ctrl3...

javascript - Polymer core-ajax cross domain issue -

I am trying to make a cross domain call using polymers and components. I'm not coming back 'access-control-permission-generation' header on request processing is not present. My code for component is below & lt; Core-ajax id = "ajax" auto url = "http://api.meetup.com/2/event_comments/?key=MyKey& event_id=191593992 & amp; callback =" on-core-response = "{{ Commentsloaded}} "method = 'received' contentType = 'text / javascript' handleAs =" json "& gt; & Lt; / Core-ajax & gt; If I use jQuery and the following snippet, then it works $ .getJSON ('http: //api.meetup. Com / 2 / event_comments /? Key = mikey and event_id = 1 915 939 & amp; callback =? ') So my question is, is there magic magic that is not polymer and how do I get around it Do you? I've checked the console and everything looks the same (headers, paramet etc.). As the appropriate name suggests in the comm...

Google map to show name of location if found, otherwise just the address -

Image
itemprop = "text"> I could use Google Maps embedded in my website to show the name of the place if found, and then just do not know So got it? I can get my code to show the address in all cases but this name is being shown in some cases. I have some examples if you look at the first line, then I can work on the map address, but not with the name of the place. In the second line, though both cases are working. I used it for The code is the first one: and the second one is for Now in the second case because Google Maps is not able to find the small + Calcutta + restaurant, it is not even searching for the address. What do I need: If the search with the name is successful, show it by name, search with the other address and ignore the name. That is possible "itemprop =" text "> yes use Geocoder Geocoder on; Map Geocoder = new google.maps.Geocoder () Before you start this add> function search () {var Address = ...

java - Hibernate @MapKeyColumn and table inheritance causing Unknown column type exception -

let me know I upgraded from Hibernate 4.2.5.Final 4.3.6.Final, 4.3.6 Hibernate Libs are creating a mysql unknown column type exception. The following sections have been simplified because I am unable to fully show the production codes of my companies. @Entity @ tables (name = "region") public square area {private integer ID; Private map & lt; BasicType, BasicConfiguration & gt; ConfigurationMap = New Hashmap & lt; BasicType, Basic Configuration & gt; (); @Id @ Generated Values ​​(strategy = generation typeIndi) Public Integer Mill ID () {Return ID; } Public Zero Set ID (Integer ID) {this.id = id; } @OneToMany (speed = FetchType.EAGER, cascade = {} CascadeType.ALL, orphanRemoval = true) @JoinTable (name = "area_configuration", joinColumns = {@JoinColumn (name = "area_id")}, inverseJoinColumns = {@JoinColumn (Name = "basic_configuration_id")}) @mamkeemannnet (EnumType.STRING) @MapKeyColumn (name = "type") public map...

ruby on rails - ActionController::ParameterMissing (param is missing or the value is empty: film): -

So, I'm having the following error when I try to go to the Movies page on my app: ActionController :: ParameterMissing (Ultimate is missing or value is empty: film): 2014-07-24T22: 04: 44.622356 + 00: 00 applications [web.1]: app / controller / saas_admin / movies_controller.rb Category Saas Admin :: Films Controller & lt; SaasAdminController inherit_resources belong_to: Studio ,: Finder = & gt; : Find_by_id !,: param = & gt; : Studio_ID ,: class_name = & gt; Studio before_filter: set_sort_fields ,: only = & gt; : Edit before_filter: build_collections ,: only = & gt; [: New, Create, Edit, Update: Creating Def] Creating! {Parent_path (parent.id)} In relation to redirecting # studios, Studio_ID has been replaced End DEF update @film = movie.find_b_partlink (param [: id]) response_to do | Format | If @movie.update (allowed_uprum) format.html {redirect_to saas_admin_studio_path (@ film.studio), notice: 'The movie was updated successfully.'...

ruby on rails - Sidekiq push_bulk to batch -

I am trying to use a group of related jobs together to use a sidekick batch for the group. However, the batch sets fire on the entire callback before time, because the jobs method can not bring all jobs fast to radis. In the Sidekick documentation it is said that it is Sidekiq :: Client.push_bulk Can be solved by using the method, but the documentation is unclear when pushing a batch in bulk. Can someone share an example of using push_bulk in the context of a batch? Assuming that you want to process 100 users per user in batch, copy per user ID per page b = sidekick :: batch.N.N.b. user user = select (: id) .limit (100) .map (and: id) # users [1, 2] , 3, etc ...] args = users.map {| Uid | [UID]} # Args [[1], [2], [3], etc ...] Sidekick :: Client. Push_bulk ('square' = & gt; your worker, 'args' = & gt; Args) End

list - Scheme filters - "wrong value to apply: #f" -

I'm trying to filter a list based on a specific thing I've written, but when I filter Wrong value to apply: #F The code of the predicate: Code> ;;; If the string is not empty or is not filled with spaces, then define (Notatts Space? Str) (if (equal? ​​Str "") #F ((call-to-on-continuation (lambda) (Return) (for each) Lambda (C) (if (not (four-white space C)) # T # F (string-> list str)) # F))))) This filter is my implementation (this is in a speech statement): (Updated-StrictList (Filter No White) Pes? Strel)) Any ideas? Thanks! so (call-in-on-continuation ...) The code is being wrapped in extra brackets, which means that the plan should take the result and run it in a moment as it should be run. In general, there is a apply process in a LISP evaluator that runs processes, for example (get-proc) define (get-proc)) (define) (display "namaskar") ((get-proc)); ==> You try to do the code like (# F) and since # F is ...

winapi - Multiple windows with shared context -

I currently have an implementation that mobile Intel works on all video cards except GM45. Unfortunately, when I try to call wglMakeCurrent (SDC, SRC); On the said video card, it crashes completely. I do not have physical access to this video card. In my method, I am reusing the same sRC based on the first sdc . Now, I have read "If both windows use the same pixel format, then use 1 GL reference for both windows" () which you can call it a reference and multiple windows (DC) And as stated, my implementation works fine on all other video cards. Fixed HDC sdc = null; Fixed HGLRC SRC = Faucet; Fixed HWND sOldWindow = NULL; Zero GfxReset (HWND Newvando) {if (sCurrentWindow! = NewWindow) {if (SDC) {AssertWGL (wglMakeCurrent (SDC, NULL)); AssetWGL (releasedDC (SCRRT wind, SDC)); } Sdc = getdc (newwindow); Emphasis (SDC); PrepareDC (SDC); // Create render reference if (! SRC) {sRC = wglCreateContext (SDC); Emphasis (SRC); } AssertWGL (wglMakeCurrent (SDC, SRC)); // cra...

c# - visual studio custom install action doesn't seem to be working correctly -

I have created a setup project that has copied all of my files into the Applications folder, which includes an accessdbengine.exe file And use the accessdbengine.exe file with the arguments set on custom install / Pasive When I run the setup it shows that it installs accessbbengine.exe, but manually accessdbengine The exe is running, but it does not look like a regular installer, Manually when you install it like does not appear in the program. My app does not work unless accessdbengine.exe is installed, if I install it manually then it works, then it does not seem that custom install action actually works Used to be. Anyone have any ideas? Link to msaccessdbengine file I Change my provider from the provider = Microsoft . AACE OLDB.12.0; For the provider = Microsoft.Jet.OLEDB.4.0; My problem solved

jquery - getting .val of select list that is loaded on through ajax -

I'm having trouble receiving .value from a selected list, I Ajax . It seems that I only give the value of the first option, even if I choose myself or not. The odd thing is that I have the $ ("select"), val () in the console; Checking for , and $ ("select"). (": Selected"); and the selected option gives an array with the first item and which I have just chosen. So it seems that this one has been selected and holds the first item, but val Only the first item is returning. This is my code: Adding my selection box (with other things) Class = 'statusChangeUsr' name = 'statusHere' & gt; & Lt; / Select & gt; & Lt; Button class = 'smallResultsButton submitStats' & gt; Submit & lt; / Button & gt; & Lt; Button class = 'smallResultsButton cancelStats' & gt; Cancel & lt; / Button & gt; & Lt; / Div & gt; "$." ($ .ActionsToolbar3 ") Attached (status...

javascript - Can't get colorbox js to load -

I'm having trouble integrating colorbox.js in the site that I'm given to work because I can not find it to show something (though I want it to show a video) Can someone see my code and tell me what I have done? HTML & lt; Div id = "bl_hp_quickLinkBoxLeftThree" & gt; & Lt; One square = 'inline' href = "#inline_content" & gt; Mole shell! & Lt; / A & gt; & Lt; / Div & gt; & Lt ;! - #bl_hp_quickLinkBoxLeftThree - & gt; & Lt; Div id = "bl_hp_quickLinkBoxRightThree" & gt; & Lt; P & gt; This is some content & lt; / P & gt; & Lt; / Div & gt; & Lt ;! - #bl_hp_quickLinkBoxRightThree - & gt; & Lt; Img src = "./ images / quicklinks / verso.png" / & gt; & Lt; Div style = 'display: none' & gt; & Lt; Div id = 'inline_content' style = 'padding: 10px; Background: #fff; '& Gt; & Lt; Video Control = "Con...

excel - Hide rows based on multiple cells -

Image
I need to hide rows in Excel based on the value of several cells in the same line. If all in my line 0 If it is empty or empty, then I need it. If there is no integer (0 or negative) I need a row shown on the same sheet I have 'section headers' which are separate sections, and below it, a row of spaces Can I leave those information? I had some partially written working lines, I could not get it together. Hope for any help Thanks and thanks! Edit: Now if I have a hidden column then I ignore the 'sum' hidden column I have tried to hunt some nests in the answer to Rowan, but no one. Hide myRow for each The range to hide for each room. If cell cell Columns Vested = false then total = total + cell.value end if next if total = 0 then 'if is the sum of the line = 0, hide myRow.EntireRow.Hidden = True End next My quick trend is on: sub row header 1 () range as hide hide range To hide the myRow range set, range = sheets (2) range ("A2: D12") ...

c# - Passing Data from Page to Page for Windows Phone 8.1 -

I have only one question, but only for Windows Phone 8.1 (in opposition to Windows Phone 7). Here's the question: I am looking for the best practice about how to pass data from page to second page. Page AI has a button that stops on Page B. Page BI has 6 text boxes allowing the user to enter information. When a user is done, click the button that brings him back to page A. I want to return that data to Page A. I have suggested: The XML class uses the API class to store documents and store in different storage properties, to store information in a query string As I pass, I am looking for the best practice. Is there anyone who is recommended by Microsoft or which is generally considered the best method? Thanks Runtime in WP8.1 - Silverlight The first and perhaps easiest way is to use it - you want it to be string If it is a serialjable type: // Assume that you have a simple class: Public class passedData {public string name {get; Set; } Public int value...

list - scheme - string-appends wrong type to apply error -

मेरे पास यह कोड है (लैम्ब्डा (प्रतीक) (चलो * ((डेन्टिस्ट ( प्राप्त सूची के प्रतीक) (खाली "") (html "& lt; तालिका सीमा = \" 1 \ "& gt;") (html (स्ट्रिंग-ऐंडेंड एचटीएमएल "& lt; tr & gt; & lt; td & gt;" 1) "& lt; / td & gt; & lt; t \ r & gt; & lt; td & gt;" (लिस्ट-रेफ डेटलिस्ट 2) "& lt; / td & gt; & lt; / tr & gt;")) () ((पी 7 (+ 7 P) () () () () () () () () () () () (डेरा (स्ट्रिंग-ऐंडेंड डे "और लेफ्टिनेंट; टीआरएसी; & lt; टीडी & gt;" (लिस्ट-रेफ डेन्टलिस्ट पी) "& lt; / td & gt; & lt ; & Lt; / td & gt; & lt; / tr & gt; "))) (सेट करें! Html (स्ट्रिंग-अपेंड html वर्ण" & lt; / table & gt; ")); td & gt;" \ (सूची-रेफरी दातावादी (+ p1) Html)) मैं मूल रूप से एक तत्ववादी से कुछ तत्व ले रहा हूं और उन्हें कुछ एचटीएमएल टैग जोड़ रहा हूं। हालांकि, जब मैं कोड चलाता हूं, तो मुझे बाध्यकारी (प...

java - PrintStream Println behaves differently on diff machines? -

I have a simple server and client software to simulate a readliner on the server running on the mac and socket in C Written is my custom code. Customers written in Java for Android and Window machines I'm seeing strange behavior with printline calls. The code looks like this printstream ps = new printstream (clientSocket.getOutputStream ()); JSONObject json = New JSONObject (responseMap); String buffer = json.toString (); Ps.println (buffer); Ps.flush (); When printlines run on windows, send buffer / r / n after the string. When running on Android, the printline sends / n after the buffer string. Should not the difference in the behavior of printline / OS / machines be compatible? Should the behavior of println not be compatible in OS / machines? PrintStream retrieves the separator from the platform's line and sends it to the built-in stream. Windows and Android have different line separators.

xcode - Trouble with nested Json data -

I have a ton of trouble trying to reach nested JSON data (pasted below). I am writing: "Create a dictionary with data within the data" as the NSDictionary as the However, Xcode will not allow me to call anything within "current_condition" such as "data". I have tried to do the current_ condition as if This is your own dictionary: var result = data result ["current_condition"] as NSDictionary but it appears that It is changing to blue form. I have also tried to use the standard method to call nested loops: var Detreshte ults = JSONSUSTT [ "Data"] ["Current Connection"] as NSDictionary but it results in a compiler error. Any help? Very much appreciated! Jason data: {data = {"current_condition" = ({cloudcover = 0; humidity = 68; "observation_time" = "01:39 am"; "=" 0.0 "; Pressure = 1017; "Temp_C" = 20; "Temp_F" = 68; Visibility = 10; ...

array and operator overloading within a struct ,from c++ to c#? -

मैं इस c ++ code को c #: रूपांतरित जीन {int alleles [ 4]; फिटनेस; फ्लोट संभावना; // समानता के लिए टेस्ट इंट ऑपरेटर == (जीन जीन) {के लिए (इंट आई = 0; आई & lt; 4; i ++) {अगर (जीएन सीलल्स [आई]! = एलील्स [आई]) वापस लौटते हैं; } वापस सच; }}; सी # में बीसीएस मुझे सूचित करता है कि मैं ऑपरेटर == ओवरलोडिंग में त्रुटि के अलावा स्ट्रेट के भीतर सरणी नहीं बना सकता, इसलिए, यह कैसे सी # में होगा? सी # में ऑपरेटर्स को सार्वजनिक स्थिर होना चाहिए इसके अलावा == ऑपरेटर की दो वस्तुओं की तुलना तर्क के मुताबिक होती है, और एक! = ऑपरेटर को भी परिभाषित करने की आवश्यकता होती है यदि कोई == ऑपरेटर परिभाषित किया जाए। इसे आज़माएं: सार्वजनिक संरचना जीन {int [] alleles; फिटनेस; फ्लोट संभावना; सार्वजनिक जीन (एंट [] एलील): यह () {this.alleles = alleles; } // समानता के लिए टेस्ट। सार्वजनिक स्थिर बूल ऑपरेटर == (जीन जीएन 1, जीन जीएन 2) {के लिए (इंट आई = 0; आई और एलटी; जीएन 1.लेसल्स. लैंगटी; आई ++) {यदि (जीएन 1 सीललेस [आई]! = जीएन 2। सीलिज़ [आई]) विवरण झूठा है; } वापस सच; } सार्वजनिक स्थिर बूल ऑपरेटर! =...

css3 - Looping Divs (jQuery Carousel) -

Image
I created a page app and everything is working by leaving a section. Here's how: I have made several attempts to get the lathes section to loop like a carousel so that the user can click the arrow indefinitely and continue to scroll the skates. The same direction I have tried some sliders, draft scripts, my own JS and CSS3 but this can not be found. Suggestions are greatly appreciated! Thanks! You have received almost ! When the second view loads, it seems that you animate the left margin of #swatchcontent -503 pixels. Instead, remove it, or animate left . It seems that it is screwing with your math. Then you just have to fix your terminal numbers. It seems that you go in the right direction before going one behind the width of a block, so reduce it and you should be good. Here I have removed the left margins with jQuery. I now use the arrows in the form of intentions (as long as you do not end, update to reset the reset position to 0 ):

c# - How to write the response to the text file -

I am trying to log request response from service to a text file. I'm using log4net to log the answer to a text file, but it is only logging the request but the response is not there. How can I do this? public void AfterReceiveReply (reference System.ServiceModel.Channels.Message reply, objected correlationState) {if (log.IsErrorEnabled) {SaveResponseToLog ( "AfterReceiveReply" + "\ n ##### VisService Soap Response ##### \ n "); String file name = environment Getfolderpath (environment. Viseshfolder. Application Data) + "\\ Daimler AG \\ vis @ \" "+" log.txt "; System.Xml.XmlDictionaryWriter writer = null; Sndeshbfr buffer = North. Kretbufrdkapi (Int32kMaxValue); Answer = Buffer. Crete Message (); System.ServiceModel.Channels.Message AnswerCopy = Buffer .Tet Message (); {FileStream FS: Try New FileStream (File Name, FileMod. Append, FileAccess.Write); Author = System .xml.xmlDictionaryWriter.CreateTextWriter (fs); replyCopy.WriteMe...

jquery - .attr('disabled', 'disabled') or .attr('disabled', true) for disabling input -

दोनों .attr ('disabled', 'disabled') और .attr ( 'निष्क्रिय', सच है) मेरे कोड में काम करते हैं, लेकिन मैं सोच रहा हूं: दोनों में से कौन अधिक कुशल और / या अधिक इस्तेमाल किया जाता है? क्या वास्तव में अंतर है? प्रदर्शन-वार, शायद? कोई अंतर नहीं करना चाहिए लेकिन jQuery1.6 + से आप $ ("इनपुट") का उपयोग कर सकते हैं। Prop ('disabled', true);

fast search in a 10 million records table with unique index column of SQL server 2008 R2 on win 7 -

I need to do a quick search in a column, in which window 7 on the SQL Server 2008 R2 table shows floating point The number includes I The table has 10 million records. The ID is the priority, I have to search for the "Price" column for any value, such that I can find the nearest point of the point given in the table. Proximity is defined as the full value of the difference between the given value and the column value. Small value, close I would like to use binary search I want to set a unique index on the value column. But, I am not sure if I search for the value given in the column, then the table will be sorted every time or not? Or, it only changes the table once because I have set the value column as a unique index? Is there a better way to do this search? Whenever I do a search then do a sorting? I need to do several times of searching in the table. I know that the time of sorting is O (n.lg n) index can actually do this for me? Or is index linked...

java - Exception while binidng form to bean using Spring MVC, JSR 303 Annotation -

I have the following spring form: Input tag in my JSP which accepts on date. & lt; Look: input type = "text" id = "fromDate" path = "fromDate" /> And I have a corresponding Java bean to force the date of the user to date by the user of the bean property. Private date from date of @NotNull @Past @DateTimeFormat (Pattern = "MM / DD / Yay"); When those "mm / dd / yyyy" format enters the date in the format I am not getting any exception and the value is being set to the bean variable properly. The user enters the date in another format when (former: 23/12/2012) or an invalid date (ex: 060412009324092014). I'm having the following exception type Java property failed to change the value of the expected type for java.util.Date from date. Property to lang.Date; The nested exception is org.springframework.core.convert.ConversionFailedException: Type to convert to java.lang.String from @javax.validation.constraints....

objective c - cocoa could not connect action -

I'm negligible with Objective-C + coco and writing a simple Cocoa app. Then I had to face a runtime error which has no effect on my program execution: Action text could not connect field: to target class bar controller I'm Menenu. Using some windows outside the XI and loading them with separate controllers and xib files. Within a new xib in a window, I have created a text field and linked it into a new NSW Dundo controller sub-section with an IBotlate Entexfield (textfield). It works and I'm able to use textField to update the contents of the text field. I'm curious why I am getting a runtime error from top and I hope the magic around some UI creation process in understanding it plain IBOutlets Really - something through the first Respondor and Response Chain And funny starts when using the binding or action sent to the unknown target: -) About your error: Looks like you've connected one of the targets Outlets for which are not present in y...

ios - fatal error: unexpectedly found nil while unwrapping an Optional value -

I'm trying to run this code but I get this error: Fatal error: Unlikely opening an optional value while opening zero I do not know what it means or why am I receiving it Any hint? Import UIKit Class ViewController: UIViewController {var last number: string = "@IBOutlet var answerField: UILabel @IBOutlet var operaterLabel: UILabel override func () {super.viewDidLoad () // Make an additional setup after loading the view, usually a nib from.} Override funk receive memory warning () {super.didReceiveMemoryWarning () / any resources that can be redone.} @Ibooting Funk Button Tap (Button: UIButton) {If answerField.text == "0" {answerField.text = theButton.titleLabel.text} and {answerField.text = answerField.text + TheButton.titleLabel.text}} @IBAction Func plusTapped (the Button: UIButton) {// Error talking about next line if operaterLabel.text == "{operaterLabel.text =" + "lastNumber = answerField Text answerField.text = "0"} and {ent...

git - Is Xcode Source Control impossible to revert a file to some version I committed? -

By using the version editor, users can compare the differences between the versions, but they can recover the old Can not ask for Xcode to replace the local version of the file version (a single single file)? Or can I not bring back some committed revisions, can I only see the history of amendment? Do not tell me to use a snapshot or branch, it's not what I want. Due to the snapshot this is not bad enough, but you are right: version of Xcode is very limited You must either use the command line to return to the previous commands or use the GIT tool like GitHub for Mac: From the command line, the CD is in your project directory and GIT checkout Use the. This and other git commands are explained in more detail here:

PostgreSQL C String to CHARACTER internal representation -

I am trying to convert a C string to an internal representation of the character of PostgreSQL. I am using the varchar.c function in the bpcharin function. There are two arguments for this function: C string datum and atttypmod . It has been mentioned that the atttypmod type plus is the declared length of VARHDRSZ. My conversion function is: result = directfunction call 2 (bpcirin, csrringGetDatum (str), VARHDRSZ +?); My string str value will be one of the columns datatype of my table. Therefore, I need the declared column data type length. This information is stored in the character_maximum_length in the information_schema.column view. My question is, how do I get character_maximum_length ? In C code? Thank you. Unless you are using the char data type You need bpchar CodeTringGetDatum (for typed values ​​for cstring ) or typed CStringGetTextDatum ( text ) Enough values) is enough. It looks like you're using char (n) , that is, bp...

Linux ODBC driver for ProvideX database -

I have a problem solved with adding a proprietary production database to the web application that is developing on the OSX platform. Using PHP Language What I have thought is that if ProvideX would be possible way to query data, web app can drag data and update itself with live data, which is an effective and possible solution for ODBC Found as. The question is, can there be any Linux ODBC driver to communicate with the Web API Prudex database? I know that the window is one for the platform because Providence is designed to work with the Windows system. Any thoughts or writing can I go to learn more about this issue? Do not try to go strictly with the ODBC driver, it works fine if you only apply for an ODBC complaint application.

php - Javascript validation: Block special characters From input text box when click on submit -

How can I enter special characters in the text box (txt_edition) by editing the code given below for verification? I want only numbers to be registered. & lt; Script & gt; Validate function form () {var x = document.forms ["frm_bokAdd"] ["txt_edition"]. Values; If (x == faucet || X == "") {Warning ("version will be filled"); return false; } & Lt; / Script & gt; Below is my form & lt; Form name = "frm_bokAdd" action = "#" method = "post" onsubmit = "return validateForm ()" & gt; & Lt; Table border = "0" align = "center" & gt; & Lt; TR & gt; & Lt; TD & gt; & Lt; Input type = "text" name = "txt_edition" & gt; & Lt; / Td> & Lt; / Tr & gt; & Lt; TR & gt; & Lt; TD & gt; & Lt; Input type = "submit" name = "book INns_submit" value = "add" &...

angularjs - Protractor phantomsJS hangs on Selenium standalone server started at http:// -

I am trying to work with Protector for Chrome and development for the server. The problem is that when I try to run a launcher with PhantmJs, it hangs: Selenium standalone server starts at http: // Nothing happens after this I've tried many different configurations, searched for open bugs or patches, but the solution could not be found. Does anyone have a clue? My configuration: Abilities: {'Browser name': 'Phatomaz', 'PharmaJSCLI Car ': [' - Ignore -ssl-errors = true ',' --web-security = false ',' -debug = true '],' pharmaceuticals. Binary path: './node_modules/phantomjs/bin/phantomjs'} your phantomJS Check the config. Ex: For Windows: You should add Photoshop for PATH. XE DIR, and 'Phatomaz. To remove Bayeri Peth: For the Sur (WS): Abilities: {'browser name': 'phatcoms',} Then: launcher test / protector-conf.js For more information, you can refer to this link:

javascript - Splitting HTML before every image tag -

& lt; div id = "d" & gt; & Lt; p & gt; एक & lt; / p & gt; & Lt; p & gt; दो & lt; / p & gt; & Lt; img वर्ग = "छवि का चयन करें" src = "कुछ" & gt; & Lt; p & gt; विभाजन करें & lt; p & gt; & Lt; p & gt; अधिक विभाजन & lt; / p & gt; & Lt; img वर्ग = "छवि 2 का चयन करें" src = "कुछ" & gt; & Lt; img वर्ग = "छवि 3 का चयन करें" src = "कुछ" & gt; & Lt; p & gt; अधिक विभाजित यहां & lt; p & gt; & Lt; / div & gt; & LT; स्क्रिप्ट & gt; // छद्म जावास्क्रिप्ट: $ ('# डी')। ('आईएमजी')। प्रत्येक (फ़ंक्शन () {var split = split.images (); अलर्ट (विभाजन);}); चेतावनी (lastSplit); & Lt; / स्क्रिप्ट & gt; छवि के बाद split = & gt; & Lt; p & gt; एक & lt; / p & gt; & lt; p & gt; दो & lt; / p & gt; दूसरी छवि के बाद: split = & gt; & Lt; p ...

node.js - Grunt server no error, not working -

The cancer is not giving me any errors, but when I go to the IP address, there is nothing. I know that the node works, because I used the node to create a nonbounce server, and it works on a single port and works fine. When I'm running a BERBONS server, it says that the port is taken, so I know that at least it thinks that it is working on that port. When I used the same files on my local machine, it works fine, and I port and it works so the barebones server does. Any clues as to what can it cause? By the way, I'm using yo to install the Konoble-Bootstrap. For the barebones server, I just do this: DIR = ~ / proj2 / www FILE = hello.js mkdir-p $ dir cat & lt; & Lt; EOF & gt; $ DIR / $ FILE var http = Expected ('HP'); Var server = http.createServer (function (request, response) {response.writeHead (200, {"content-type": "text / html"}); response.end ("& lt; html & gt; & lt; Body & gt; Hello World &...

java - Align the Button to center Background -

Image
I need to align the background button. I need to output like an attached image button to all the blue background There should be a coalition in the center, not the logo. & lt; Relative layout xmlns: Android = "http://schemas.android.com/apk/res/android" xmlns: tool = "http://schemas.android.com/tools" Android: layout_width = "match_parent" Android: layout_height = "Match_parent" Android: background = "@drawable / feedback_bg" & gt; & Lt; RelativeLayout Android: id = "@ + id / frame_title" Android: layout_width = "match_parent" Android: layout_height = "wrap_content" & gt; & Lt; See Android: id = "@ + id / background" Android: layout_width = "match_parent" Android: layout_height = "75dp" Android: background = "@ drawable / topbluebar_and" /> & Lt; ImageView Android: ID = "@ + ID / Logo" Android: layout_width = "wrap_c...

java - Issue with @Value and application.properties since moving to Spring Boot 1.1.4.RELEASE -

I have a problem because I have moved to version 1.1.4 of Spring Boot. My values ​​are annotated with the value @, despite being present in the application, prices are not being populated yet. Properties Before I was using Spring Boot @ version 1.0.2, and it was working fine. All this started after the upgrade, and I did not make any code changes. Sample Application.Java Package org.sample; Import org.springframework.beans.factory.annotation.Value; Import org.springframework.boot.SpringApplication; Import org.springframework.boot.autoconfigure.EnableAutoConfiguration; Import org.springframework.context.annotation.ComponentScan; Import org.springframework.context.annotation.configuration; Import org.springframework.context.annotation.PropertySource; Import organization Source: @Configuration @ComponentScan @EnableAutoConfiguration @PropertySource (value = "classpath: application.properties") public class SampleApplication {private static Logger logger = LoggerFact...

asp.net mvc - Image's styles are ignored by iTextSharp -

Image
छवि .cshtml फ़ाइल के अंदर: & lt; img src = "~ / content / चित्र / आईएमजीहेड.png "स्टाइल =" सीमा: 4 पीएक्स ठोस # एफएफएफएफएफ; सीमा-त्रिज्या: 10 पीएक्स; बॉक्स-छाया: 2 पीएक्स 2 पीएक्स # एफ 2 एफ 2 एफ 2; "/ & gt; यह ऐसा माना जाता है: यह ऐसा दिखता है: संपादित करें: नीचे की पंक्ति HTML आउटपुट पर पहली छवि (गोलाकार कोनों) को बढ़ाती है पीडीएफ आउटपुट पर दूसरी छवि की तरह दिखता है शैलियां परवाह नहीं की जाती। & lt; tr & gt; & Lt; td align = "center" शैली = "ऊंचाई: 120px;" & gt; & Lt; img src = "https://abcstorage.blob.core.windows.net/Images/head.png" शैली = "सीमा: 4px ठोस #ffffff; सीमा-त्रिज्या: 10px; बॉक्स-छाया: 2px 2px # f2f2f2 ; "/ & Gt; & Lt; / टीडी & gt; & Lt; / टीआर & gt; यह रेंडर () विधि है: का उपयोग करते हुए (var pdfDocument = नया दस्तावेज़ (पेजसिज़। ए 3, हॉरिज़ॉंटल मार्जिन, हॉरिज़ॉंटल मार्जिन, 110, 30)) {पीडीएफड्राइटर पीडीएफड्राइटर = पीडीएफ लेखक। गेट इन्स्...

mysql - how to get universal date time in c# -

I am in critical condition while developing a library management system, if a book returns, to insert book details One function is to take the date of the system as the date returned to the database, then by comparing the date of the lending and the date of return I can calculate properly, but this is the fact that from the date above the current date Change system date Taxes can be returned to the book without affecting it properly It incorporates the date of the system as the current date and it has now been changed. Example: It seems that the loan term is 7 days the lending date is 11/05/2012 return date 20 / 05/2012 (looks like it is today and it gets in the form of system date) There are now 2 days of delay (so it is OK to calculate) If I change the date of the system to a previous date like 15/05/2012, it takes the date of the system as the date changed, so a book can be returned without properly calculating, whose Census should be fine? There is no way to do...

ios - In Xcode 6 Beta 4 stroking with SKShapeNode doesn't work anymore -

This works fine in Xcode 6 Beta 2, but it does not work anymore in Beta 4. Does anyone know what is behind this secret? Let's circle = SKShapeNode (circleOfRadius: 125); Circle.strokeColor = UIColor (red: 255, green: 255, blue: 255, alpha: 1.0); Circle.lineWidth = 4 self.addChild (Circle); -Text "itemprop =" text "> While using this simulator, there is a common problem with encode 6 beta 4. It works worthwhile It is worth noting that this issue is unique to stroking in that setting, which is still the circle (or whatever your SKShapeNode is drawing) properly Also keep in mind that when RGB values ​​(inclusive) between 0.0 and 1.0 circle.strokeColor = UIColor (red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0); or alternate form Use presets from: circle.strokeColor = UIColor.whiteColor ()

32 bit Linux kernel in Android system: need 64 bit timestamp in microseconds -

I have 32 bit systems which need to get timestamp value in 64 bits in Microsoft Linux on the Android system Does its direct kernel export function calls to get it? I saw jiffies for 64 bit and have functions which convert 64 bit Jeff into nanoseconds. Div Class = "post-text" itemprop = "text"> The kernel timestamps are in nanoseconds. You can get getnstimeofday () , ktime_get_ns () , or getrawmonotonic () to get a struct timespec , or ktime_get_real () or ktime_get () a ktime_t to get; The latter is ktime_to_ns () . With 64-bit nanosecond counters can be converted.

multiple condition in store procedure sql server -

I need display data on the grid with the store process in two situations. First, select if the filter is zero or empty = result 'from the partition where idle = 1' and if the filter is not zero. I want to select from division * where the code ... and this is my query. What is wrong? Please help in deciding ... announcement @philter varchar (100) DECLARE @ SQL varchar (4000) SET @sQL = 'SELECT * SET @sql = @sql +' from the division '%' + @ Filter + '%' like the 'if' filter @ is zero or @ filter = 'sittel = sql = @ sql +' iactive = 1 'and elast seel = ssll +' code ' I will help this by query below DECLARE @ code varchar (10) --- Input parameter DECLARE @IdFilter int = 0 If ISNULL (@code, '') = '' SET @ Choose IdFilter = 1 WHERE The division is WHERE (@IdFilter = 1 or '%' + 0x + '%' as the code) and ISActive = 1

php - How to list modified files? -

I am developing a security mother-in-law and I need to create a script that constantly crawls all public files on the server And alerts me It has to work on Windows / Linux. Which languages, libraries or scripts should I use? Thank you for your valuable advice. As you have tagged your question with PHP, I suggest you to use PHP language ^^ Because you said that this cross platform should work, which you can not use the filemeter. I will suggest you to create a hash database (repeater!), You md5_file for this. In your cron job you crawl again and compare the file hash, if a hash has changed the file after the last check.

selenium - How to accept all the alerts of a website? -

While browsing a webpage, I sometimes get alerts, how can I accept every warning that appears? I do not know what the number of alerts given in the given webpage is. You can set capabilities. However, certain capabilities can not be applied to certain browsers, test it yourself (as my knowledge is, it only works with FF). abilities .setability (capacit type. UNEXPECTED_ALERT_BEHAVIOUR, accepting unexpected AlertBavier);

jquery - How to add a DOM Element in a overflow:hidden area? -

I am creating a control that displays table-data per year. DOM elements are added to the table in div which is set to overflow to hidden it happens. The position in the tables is set to relative . The height of height is determined at the height of a table so that only one table appears at a time. I have paging mechanisms, which animate the transition by changing pages further and backward and transitioning the top properties so that it looks like table-data and above The side is growing like the classic calendar The problem I am facing is this: When a new element joins, I would like to add it to the hidden part of the contents of the existing table at the top, in order to store it in the Dom tree. After adding it to animate to see if it is possible without "hacks"? I have tried to change the properties of tables before adding head to div , but this' overflow: hidden Part of div . How do I get it? This is what I have done so far in JSF...

php - How can ignore a string in quotes in this regex match? -

How can I ignore the examples of string "or" when inside single / double quotes? The current expression is / ^ (? = \ $) (. +?) (?: \ S + or \ s +) (. +?) $ / S Test value 1: $ test or "default value" Test value 2: $ errors- & gt; Is ('email')? 'Error or failure': '' Test value should affect 1, but value 2 should be unaffected. Test Script: To update $ expression . & lt ;? Php function issetDefaults ($ value) {// Original expression with problem // $ expression = '/ ^ (? = \ $) (. +)) ??? s = ++++++ (++) ) / S '; // @ Avinash Raj's version; Almost there; Test 2 $ has failed on expression = '/ ([\' 'altered] (??? :: ?? \\).) * Or (? :(?!? 1).) ****** **************************************************************************************************** ***). ^ (\ S +) or ([\ '"]. * [\'"]) / '; Return preg_replace ($ expression, 'provider ($ 2)' $ 2: $ 3 ...