Posts

Showing posts from March, 2012

jquery - How to display a bootstrap popup box after a file is selected from file browser window? -

So, I have a drop-down list that contains a button to import files from the system: & lt; Input type = "file" id = "file selected" class = "upload" data-toggle = "modal" value = "import" data-target = "# import data" /> Therefore, when the user selects the file from the file browser and clicks on "OK", then a bootstrap modal box should be displayed which displays the details of the file that is selected I went. Code for Bootstrap Popup: & lt; Div class = "modal fade" id = "IMPORTDATA" data-background = "static" tabindex = "- 1" role = "dialog" aria-labeled = "phthomologin label" array-hidden = "true" & gt; & Lt; Div class = "modal-dialog" & gt; & Lt; Div class = "modal-content" & gt; & Lt; Div id = "popupDiv" ng-show = "popup" class = "col-sm-12" &...

java - How build hadoop sources under windows? -

Windows 7 x 64 is trying to create data from sources. According to the instructions I have cloned the houp sources, run root / branch-5 (SHA-1: fa3bb675a728105d69614f53abe4339958550adf) in the checkout again with the Windows console: > Set platform = x64 Install clean - PDIT, native-win-skeptestst-data Get more error - [ERROR] Failed to execute target org.apache.hadoop: Thup-Maven plugins: 2.5.0-SNAPHHT: Protocol on project Still-protoc): Haup-Common: org.apache .maven.plugin.MojoExecutionException: 'Protocol - version' did not return a version - & gt; [Help1] Any ideas how to solve it? Firstly, the use of Protoco mojo of Whoop-Maven-Plugin will be used by Java's java.lang The Process attempts to execute the following commands: Basically it is being used to check that the protocol version of the protocol buffer compiler (protocol) on your system Protobuf matches JAR version. There are 4 results for this: The command protocol c...

rfid - Idle time function on an Arduino -

I want to add a timer to this function so that every time the UID is read and it restarts and I set up another function After reaching a certain time, write a serial. Let's call it a passive time function. I can not tie this id for reading because I have 28 IDs being read potentially. I want to reset my audio player via serial with an ASCII command. If no IUD has not been read for more than 180 seconds ... suggestions? if (uid [0] == 0x64 and uid [1] == 0xBF & amp; uid [2] == 0xD8 and uid [3] == 0x51) {// delay in the beginning (500); //Serial.write (for Bässgen MM3210) Serial.write ("listplay 1 1"); Serial.write (13); Finally break at break // 3000 (); } "post-text" itemprop = "text"> You can assign one value to each UID by calling () call. Since the chip started, it basically calculates milliseconds, it gets stored in the long run, so every 80 days is reset to zero or I think that ( I have never left it) I wrote this time on the ...

specifications - Formal way to describe protocols -

Is there a formal / traditional way to describe the data / command exchange protocol? For example, there are many approaches to describing syntax and semantics (such as :) for programming languages. The approach I am looking for is useful (as opposed to academic). While working on specifications, I need something for day-to-day usage for data exchange details, just to transfer / spread the views of other people. Therefore, if there is anything that is not recognized as a D-Facto standard but useful - it's OK too. I took a look at the UML sequence diagrams and the details of the "payloads" in the pre-system are missing by "formal method for communication protocol specificity and verification, Carl A. Sunshine, 1979" (less than Less what I had understood), while the other is rather an enlightening letter, which describes ideas rather than methods (although I am still going through this letter). Thanks in advance Send the protocol according to a seri...

javascript - in kinetic js fill element(shape) with image -

I'm making different shapes within the canvas inside Kainet. I put the image in size, but not able to resize the image inside the shape. Users will give X, Y, Height and Width input of the image. Then the given size image will be sized in size. Due to low reputation, I can not insert images here. You can easily see that you have understood my question This is my code sample $ (img) .load (function () {blueCircle.fillPatternImage (img); blueCircle FillPatternOffset ({X: 100, y: 105}); layer.draw ();}); Img.src = ""; Yngksrk = "Actiteepi://wwwkfusemobilekcomkaw/vp-kantent/uploads/20ll/ll/mobail-soshl-netvrk-300x225kjpg"; You fillPatternScale (scale) to Scale you can use, for example: $ (img) .load (function (to) {blueCircle.fillPatternImage (img); blueCircle.fillPatternOffset ({x: 150, y: 105}) ; Bluearch FillPatternScale ({x: 0.4, y: 0.4}); layer.draw ();});

Why Python doesn't catch exceptions raised in C++? -

I am trying to create a Python iterator in boost :: python. So I have the function PyObject * my_iterator_next (MyIterator * iter) {if (! Iter- & gt; is_end ()) {return * (* iter) ++; } Other {PyErr_SetNone (PyExc_StopItation); // It does not work either PyErr_SetString (PyExc_StopItation, "End of Archive"); Return tap; }} In Python: MyContainer for X in and I can find: 1 2 3 No account pack (most recent call final): file "main.py", line 6, & lt ; Module & gt; Print (x) stop bitation: end of collection besides this = my_collection .__ iter __ () try: it .__ next (__) ; This .__ next (__); This .__ next (__); This .__ next (__); This code does not print anything, so no exceptions have been captured. Why? After setting the dragon exception, you should notify Boost like this. Python is as follows: throw_error_already_set (); View

android - Eclipse lost shortcut for inspect while debugging ctrl+shift+i -

Image
I'm trying to restore a shortcut with a succcess by clicking on CTRL + SHIFT + I There was a shortcut for but now I do not have this feature available, it seems that has disappeared. Any ideas of restoring it? Thanks! Finally I found this command: To access this page, you must go to: Windows-> Preferences-> General- & Gt; Shows pictures such as Keys and Restore

php - Codeigniter URLs showing 404 -

I have a simple web hosting platform, I'm hosting a Codeigniter application on / var / www / html which means That this file structure is: html | -Application | --- Controller | --- model | --- view --- config | -public | -System | -Instructions. Php | -htacess My .htaccess file looks like this: & lt; IfModule mod_rewrite.c & gt; RewriteCond rewrite code% {REQUEST_FILENAME}! -f rewrite code% {REQUEST_FILENAME}! -d RectitRule ^ (. *) $ Index.php / $ 1 [L] & lt; / IfModule & gt; In my config.php file, I have the default Root View Controller: $ config ['base_url'] = 'http: // www example .com / '; In my routes In the Php file, I have the www in my browser, when I have $ route ['default_controller'] = "home" When opening mysite.com I get the home / index automatically but when I like any other URL www.example.com/home www.example.com/home/index www .example.com / admin I get a 404 error It is also worth...

vb.net - Precompiled in asp.net application not required -

I have a website project and some other projects that are bound by a solution file. When I create a solution using Visual Studio, it is not making a precompiled version of the website, but creating a precompressed version using msbuild to create a solution. We do not use pre-assembled code to deploy on the server, so this version is not necessary in our process. And it takes a lot of time to make it. How can I avoid building a pre-compiled version? Is there a switch or function that I can use to create a solution in the msbuild script? I need MSbilt to just build the solution Currently the command I am using: msbuild "ABC.sln" The MSBuild A / T switch features on the command line, which allows you to define the build target. You will use this switch to target all other subfolders of the solution.

javascript - How I can add a counter after adding a new - to my list using jquery -

After adding a new row at the top of my list, I try to apply a dynamic counter to add to my list The code is not working properly because it is wrong, for example if we have this list A b And I will add D instead of making it like this D A A Come c Relationship I want to delete the last line if I down a new line add, but what is not working no one knows why? A A variable that holds the content that I want to prepaid $ (". Il_admin -" + id) .prepend (html) .slideDown ("slow"), a ???? Var i = GetURLParameter ("paged"); Var calculation = (i * 10) -10; JQuery ("Il_admin li"). Each (function (i) {i = count + i; var text_attreibute = $ (this) .find (".l_admin_raw_count"); $ (text_attreibute) .html (i + 1);}); Var size = $ ('. Il_admin li') Size (); If (size> 10) {var last_row = $ ('. Il_admin li'). last (). Attr ('class'); $ (LAST_ROW) .remove (); } jQuery ("...

html - Javascript code is not working -

How can I modify the code so that when I first select an option from the drop down menu, edit the second drop down menu Eligible, otherwise the second drop-down menu should be read only, and if the option is "default" in the first drop down menu then the second drop down menu should be read-only. & lt;! DOCTYPE html & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; Script type = "text / javascript" & gt; Function mySecondFunction () {document.getElementById ("mySelection"). Disabled = false; } & Lt; / Script & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; Form action = "" & gt; & Lt; Select name = "car" onload = "mySecondFunction ()" & gt; & Lt; Option value = "default" & gt; Default & lt; / Options & gt; & Lt; Option value = "saab" & gt; Saab & lt; / Options & gt; & Lt; Option value = "fayat...

java - How to connect to mysql with eclipse in android -

I am trying to connect to the MySQL database in Android Eclipse and my SQL-connector-Java-3.1.12- I am also using bin. But it shows me the message: Failure due to the underlying exception and it is not connected yet I am using the same thing to connect to my Java programs in NetBeans. Any help would be appreciated. Package com.bookapp; import java.sql.SQLException; Importroid.os.Bundle; Import android.view.View; Import android.view.View.OnClickListener; Import android.widget.Button; Import android.widget.EditText; Android Import; Spinner; Import android.widget.Toast; Import android App Import android.content.Intent; Public class enhances PersiansIno activity (protected void onCreate) (bundled saved instenstate) {super.onCreate (savedInstanceState); SetContentView (R.layout.personalinfo); Try {StudentDA Promotion = New Student (); For (string jshdjsd: stud.GetAllUniversities ()) {Toast TT = Toast. Make text (personal info., Jshdjsd, toast.ln.gov_LOG); Tt.show (); } // for eastu...

c# - SignalR with Certificates -

I want to make a simple signalar application. Using Http Everything works fine, but when I try to use https and certificates the application does not work. Now, the only thing I want to do is get the client's certificate in the server. Server (Authentication Handler): Public Class Client CertificateConfirmation: Authentication Handler & lt; Customer CertificateOfficial Option & gt; {Safe Override Work & lt; Authentication ticket & gt; AuthenticateCoreAsync () {var cert = context.Get & lt; X509 certificate & gt; ("Ssl.ClientCertificate"); If (cert == null) {return Task.FromResult & lt; AuthenticationTicket & gt; (Empty); } Try {Options.Validator.Validate (cert); } Hold {return work.formersalt & lt; AuthenticationTat & gt; (Empty); } Return tap; }} Customer (hub) var connection = new HubConnection ("https: // localhost: 8080 /" ); Connection.AddClientCertificate (X509Certificate.CreateFromCertFile (...

ios - NSOrderedSet is not convertible to NSManagedObject -

Image
I'm partially following the tutorial with Ray Vendorlich (if you search for 'Save Run' This should jump in part about this question). I have also tagged it with 'swift', because I do not know that it is fast due to any problem (because it is working in the tutorial which is in Objisi). I'm currently stuck on saving location data in the CoreData data model. Code here for my saved session method: func saveSession () {var newSession: session = NSEntityDescription.insertNewObjectForEntityForName ("Session", Managed Object Contex: Management Object Contains!) As the session new session.imestamp = NSDate () var tempArray = [AnyObject] () for self. Place newlocationArray {var location: location = NSEntityDescription.insertNewObjectForEntityForName ("Location", Managed Object Contact: Self.managedObjectContext!) As the location location. Timestamp = newLocation.Timestamp location.latitude = newLocation.coordinate.latitude location.longitud...

unix - "skipping incompatible /usr/lib/libc.so when searching for -lc" issue while make tls package in Linux -

मैं make tls1.6 करते समय समस्या से नीचे का सामना कर रहा हूं। / usr / bin / ld: अनजाने में लंघन / ls / libc.so जब- -lc के लिए खोज: libtls1.6.so (गूंज 'पैकेज ifneeded tls 1.6 \ "[सूची स्रोत [फ़ाइल $ dir tls शामिल हो टीसीएल]]; \ [सूची Tls :: initlib $ dir libtls1.6.so] "'\) & gt; PkgIndex.tcl संभव प्रस्तावों क्या हो सकता है? निम्न चरणों पर जाएं। आप tls के साथ बनाने क्या वास्तुकला के खिलाफ की जाँच करें libc.so lib। के लिए आपके पास एक ही आर्किटेक्चर के साथ कोड> टीएलएस पैकेज है। आप बाइनरी फ़ाइल का लक्ष्य वास्तुकला निर्धारित कर सकते हैं Libc.so साथ फ़ाइल इस तरह से linux आदेश: फ़ाइल / यूआरएल / लिब / libc.so / / कोड>

r - Can I programmatically update the type of a set of columns (to factors) in data.table? -

I would like to modify a set of columns within a data, which is the factor. If I knew the names of the columns in advance, then I think it would be straightforward. Library (DataWabel) DT1 & lt; - data.table (a = (1: 4), b = representative (c ('a', 'b')), c = rep (c (0,1)) dt1 [, class (b)] dt1 [, B: = factor (b)] dt1 [, class (b)] but I'm not, and instead there is a list of variable names vars.factors & lt; - C ('B', 'C') I can apply factor function to them without a problem ... lapply (vars .factors, function x) get DT1 [, class (obtained (x)]) lapli (warfactor, function (x) dt1 [, factor (x)) lapply (wars. Factors, function (x ) DT1 [, Factor But I do not know how to reassign or update the original column in the data table. This fails. (X): in # get (x) Error: Invalid first argument lapply (vars.factors, function (x) dt1 [, x: = factor (get (x))]) # code> It is not ... Lapli (warfactor, function (x) dt1 [...

expresso store - Ajax Form submission on select change -

I try to submit a form with the class '.basket-form' on the change of a selected field with the ID I am here. #shipping_country ' I have tested the incident on change and its running. For some reason I can not get to submit the form. $ ('basket-form # shoeping_graphy'). ('Change', function () {$ ('basket-form') .Ajaxform ({datatype: 'Jason', submit before: function () {$ ('Shipping-val p'). Loading ...); $ ('. Tax-val p'). Text ('Loading ...'); $ ('total-val p' '. Text (' Loading ');}, Success: function (data) {$ (shipping shipping) .HTML (' & lt; p & gt; '+ data.order_shipping_total +' & lt; / p & gt; '); $ (' tax Val ') HTML (. & Lt; p & gt;' + data.order_tax + '& lt; / p & gt;'); $ ('total-val'.) HTML ('& lt; p & Gt; '+ Data.order_total +' & lt; / p & gt; ');}});}); Anyone hav...

javascript - Simplify a working function to replace specific words? -

I have a word, when a few words are labeled to collapse (to accommodate different proposals) My work is working, but I think it can be made simple ... just not sure how I add more words here, repetition can be faster than hand, do I have an array long I can put words / short words and everything is the same Or I could feed some things? I could not work for Bela (though she is working on my project), but you can go here. thank you in advanced! if ($ ('label'). Height ()> 20) {Warning ('Text wrapped'); Var numtext = $ ('label: contains ("number")) if numtext {numtext.each (function () ($ (this) .html ($ (this) .text (). Replace (' number ', '#'));});} Var pertext = $ ('label: contains (percent)} (pertext) {pertext.each (function () {$ (this) .html ($ (this) .text (); Substituted ('percent', '%'));});} var invtext = $ ('label: contains "(invoice) {invtext} {invtext.each (function () {$ (this ) .html ($ (t...

multithreading - C# Application waiting until Thread is complete? -

इस सवाल का पहले से ही एक उत्तर है: 8 जवाब मेरे पास एक आवेदन है जहां एक थ्रेड संख्याओं के एक गुच्छा की गणना करने के लिए उपयोग किया जाता है लेकिन समस्या यह है कि थ्रेड पूर्ण होने से पहले आवेदन समाप्त होता है और गणना संख्या देता है गणना करने तक इंतजार करने का तरीका क्या है? यहां मेरा कोड है: नामस्थान थ्रेड वाइटिंग {वर्ग का कार्यक्रम {सार्वजनिक स्थैतिक इंट संख्या = 0; सार्वजनिक स्थिर शून्य मुख्य (स्ट्रिंग [] आर्ग्स) {थ्रेड टी = नया थ्रेड (गणना); t.Start (); // संसाधित होने तक यहां प्रतीक्षा करें? Console.WriteLine (संख्या); Console.ReadKey (); } निजी स्थिर शून्य की गणना (वस्तु obj) {number = 2 + 2; }}} यदि आप इसे चलाते हैं, तो आप देखेंगे कि यह "0" प्रिंट करता है और "4" नहीं। किसी भी विचार वाले लोग? धन्यवाद! एक थ्रेड होने तक प्रतीक्षा करने के लिए, आप इसमें शामिल हों : t.Join ();

jquery - Avoid rapid clicking on button in website -

I'm working on the HTML part To click on that button I have a button, press TogglesSlide () on the div. If I click on that button fast 4-5 times drop down, then sometimes I get annoyed, I want to avoid it. Thanks in advance. & lt; Button name = "dropdown" id = "dropdown" /> & Lt; Div id = "dropdown1" & gt; Dropdown text here & lt; / Div & gt; Click here for $ {document} ($ {"(" # dropdown ") (function () {$ (" # Dropdown 1 "). TogglesSlide ();})}) Problem: On a click several times in a moment (faster) it clicks the button as much as I Clicked. There is no need to cancel clicks, you need animation $ ("# dropdown").;}); # dropdown 1 {height: 200px; Background color: yellow; } & lt; Script src = "https://ajax.googleapis.com/ajax/libs/JQuery/1.11.1/jquery.min.js" & gt; & Lt; / Script & gt; & Lt; Button ID = "dropdown" & gt; T...

javascript - Get more than 1 message from Gmail.Thread -

When I run this script, I get 1 from address, I already want to get 5 addresses, Code> GmailApp.getInboxThreads (0, 5) [0]; But that does not work, what should I do if I need 5 or more? Now it only processes 1 mail / thread // thread in first message sender to log intrread = GmailApp.getInboxThreads (0, 1) [0]; Var Message = EtherthGetMessage (); For (var i = 0; i & lt; messages.length; i ++) {logger.log (message [i] .getFrom ()); }} understand! var thread = GmailApp.getInboxThreads (0, 5); (Var i = 0; i & lt; threads.length; i ++) {var message = thread [i] .getMessages () [0]; Logger.log (message.getFrom ()); =)

ruby on rails - How to monitor a delayed_job started using jruby-rack-worker? -

I have a jruby on Rail based applications posted on Tomcat using a war file generated through Warbler Mani. I started an employee using jruby-rack-worker to work late. All jobs are being processed properly but I have setup tools to monitor the worker. How do I get the current status to work late? This gem lets you delay jobs. I use it and do great work

javascript - XMLHttpRequest not working - no errors -

I am trying to do this simple request but I am not very fortunate. I have a "test.txt" file in the server file, as is my HTML file with the script below. I have seen the file with the same result in Chrome, Firefox and IE11. I can only see the text "Initial text in the html page" from the html page. No error and text from my test.txt file is showing. Can anyone tell me what's the problem with my code? & lt ;! DOCTYPE html & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; Script type = "text / javascript" & gt; Var xmlHttp = createXmlHttpRequestObject (); Create function xmlHttpRequestObject () {var xmlHttp if (window.XMLHttpRequest) {xmlHttp = new XMLHttpRequest (); } And {xmlHttp = New ActiveXObject ("Microsoft.XMLHTTP"); } Return xmlHttp:} function process () {if (xmlHttp) {try {xmlHttp.open ("GET", "test.txt", true); XmlHttp.onreadystatechange = handleServerResponse; XmlHttp.send (z...

javascript - How do you pass the parameter in an event that requires a function? -

इस कोड को ध्यान में रखते हुए: $ ("# divToBeClicked")। On ('click ', समारोह (ई) {// कोड का बड़ा ढेर}); 'ई' पैरामीटर पर () विधि द्वारा पारित किया जाता है। मुझे इस फ़ंक्शन के अंदर कोड को एक अलग फ़ंक्शन में विभाजित करने की आवश्यकता है, क्योंकि यह बहुत बड़ी है अब, यह सिर्फ ठीक काम करेगा: $ ("# divToBeClicked")। पर ('क्लिक करें', फ़ंक्शन (e) {otherFunction (e, param2, param3);}); लेकिन जैसा कि मैं उत्सुक हूँ, मैं सोच रहा था कि यह कैसे करना है: $ ("# divToBeClicked")। (' क्लिक करें ', अन्य फंक्शन (ई, पैरामा 2, पैरा 3)); कैसे हो सकता है, तो मैं इसे पूरा कर सकता हूं? अगर मैं इसे इस तरह से कोशिश करता हूँ, ई अन्य फंक्शन में अपरिभाषित है ()। ध्यान दें कि मैं इस फ़ंक्शन के लिए अतिरिक्त पैरामीटर पारित कर रहा हूं। आप या तो इसे डेटा के रूप में पास कर सकते हैं जो इवेंट ऑब्जेक्ट पर उपलब्ध है फ़ंक्शन myfunc (e) {console.log (e.data); } $ ("बटन")। पर ("क्लिक करें", {"a": "apple...

Python: Edit Google App engine default login page ( _ah/login ) -

पायथन पर आयात स्टेटमेंट google.appengine.api आयात उपयोगकर्ता से है ... कोड उपयोगकर्ता डेटा को पुनः प्राप्त करने के लिए users.get_current_user () है। लॉगिन पृष्ठ बनाने के लिए कोड users.create_login_url (self.request.uri) साइन इन यूआरएल बनाया जाएगा। उपयोगकर्ता इसे क्लिक करने के बाद, उन्हें इस पृष्ठ पर पुनः निर्देशित किया जाएगा मैं इस पृष्ठ को कैसे संपादित करूं? मैं इसे कस्टमाइज़ करना चाहता हूं। मुझे पता है कि मैं अपना अपना उपयोगकर्ता नाम और amp; पासवर्ड पाठ फ़ील्ड लेकिन फिर मुझे सत्र डेटा बनाए रखना होगा Google ने पहले ही ऐसा किया है, इसलिए मुझे दोहराने के लिए यह प्रतिगामी है उदाहरण परियोजना पर उपलब्ध है प्रश्न यह है कि मैं इस पृष्ठ को कैसे संपादित करूं? या मैं सत्र डेटा को संग्रहीत करने के लिए उपयोगकर्ता एपीआई का उपयोग कैसे कर सकता हूं? पता चला कि मैं Google का उपयोग नहीं कर सकता से कस्टम प्रमाणीकरण करने के लिए एपीआई

json - uninitialized constant Api in Rails app -

IVE created a controller named People Controller: To guide some guide pointers of this guide Trying: / P> module API module V1 category public controller & lt; ApplicationController Def Salutation: json = & gt; {Message: "Hello World!"} In this controller there is a simple Hello method, which is called Hello world when it is called Jason My Way: Rail Application Routes. Draw Namespace: API, Default: {format: 'json'} Place name: get v1 "/ Hello" = & gt; "People #happy", like: & gt; 'Hello' and end So if I call this URL then I should get Jason response: /api/v1/greet.json But instead I get the unrefined continuous API I am doing, and about 4 hours of struggle, I can not really know what I did wrong. What is this that I have done wrong? Eager_load in your config / environment / development.rb config = True

Testing with PICT, but incomplete testcases -

I am testing the problem of a triangle in PICT I am testing if the triangle is an equilateral triangle, an isosceles triangle , Or a scalin triangle. The problem is that as a result, I never get the equilateral triangle side 1: 5,6,7,8,9,10 side 2: 5,6,7,8,9,10 Side 3: 5,6,7,8,9,10 Type: ([side1] = [side 2]) or ([side 2] = [side 3]) Or ([side 3] = [side 1])) then [type] = "isosceles" EL Sai [type] = "Skailin"; If [[type 1] = [side 2]) and ([side 2] = [side 3]) and ([side 3] = [side 1]) then [type] = "occasional"; But the random thing is that when I change the last line in IF (([side1] = [side2]) and ([side 2], = [Side 3]) and ([side 3] = [side1])) then [type] = "isosceles"; I get random values, resulting in an equilateral triangle How can I ensure that I have these values ​​in the right code? Try this: side 1: 5,6,7,8,9, 10 Side 2: 5,6,7,8,9,10 Side 3: 5,6,7,8,9,10 Type: Equatorial, Occasional, Scalene IF (([1] = [Side 2] and ...

php - unset variable done before it should unset -

I have a peace of this code, which I do not understand is that it is not working due to my work is. post it redirects and resonance is not but I hope it If I extract the line with unset, it works fine and resonance is done . This is not the behavior that I expect to do, what am I doing wrong? does not stop execution of a header redirect script, hence is unset {$ _SESSION ['reg'] = "done"; Header ("Location:". Self, true, 302); ($ _ Session ['reg']) and ($ _SESSION ['reg'] == "done"))) () (without set ($ _ session ['reg']; echo "finished"; } Else {Echo "did not";}? & Gt;

xml - Is this really not a valid xs:decimal? -

Here xmllint is telling me: is not a valid value of '1024663.719008264462809917' Type 'xs: decimal' Is there a default number of valid places? It is not considered accordingly. Update: Experiment with XMLIT, 17 decimal places are valid, but 18 is not valid. indicates that all must be at least consistent · Processor should be · Supporting decimal number with at least 18 decimal digits (i.e., total of 18 · figures ·); · At least analogous processor · fixed · fixed · fixed · Set limit · Maximum · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · P · while theses Does that allow the data type is arbitrary precision decimal numbers, a special processor, allowing to limit the range of values ​​that are willing to support it.

python - Django read cookie in template tag -

Is a cookie readable in this template tag? I have set a cookie in a middleware but I want to read in a template tag. def process_response (auto, request, response): response.set_cookie ('changed', 'yes') response.set_cookie ('select', request. LONGGUAGE_CODE) Return response thanks you le_context register.simple_tag (le_contact = True) def = Request COOKIES.get ('cookie_name', '') return result

Do we have Sequence in Sybase -

I see tutorials about syntax and sequence with examples. But when I try to make a sequence through squirrels in Sirabase, I get an error. Error: 'Sequence' is not a recognized buyer option. SQLState: ZZZZZ error code: 155 How can we create an auto industry unique identifier in Sybase? How do we use the sequence in the sequence, how the sequence is available in a Sybase version and not in the other. I connect to dependence using dependence below. & lt; Dependency & gt; & Lt; Group & gt; Com.sybase.jdbcx & lt; / Group & gt; & Lt; ArtifactId & gt; Jconn3 & lt; / ArtifactId> & Lt; Version & gt; 6.0 & lt; / Edition & gt; & Lt; / Dependencies & gt; A sequence of objects is not present in Sybase ASE (perception). Equivalent functionality is used through identity columns. Enter test_tab (test_tab_name) values ​​('hello') in test_tab (test_tab_name) value ('world') test table_ta...

C program to split char using strtok and strchr -

I have the following for C programming for C program * A user in its format entred value In some cases, the entered value is "/ 222" four * ptr = "/ 222" is usually "111/222" (the correct output output code) ; Char * val1, * val2; Val1 = strchr (ptr, '/'); If (val1! = NULL) val1 ++; Val2 = strtok (ptr, "/"); myoutput: val1 = 222 val2 = 222 How do I know val1 = "" (as an empty character) val2 = 222 Thanks in advance for ur help! The easiest way is whether your string should start with / or not. If then, val1 is to be indicated by "" and "val2" (ptr + 1). Otherwise what you currently do

javascript - How do you set a variable to the value returned from prompt('...')? -

In the code below, when I set the user variable in the indicated user input, the user adds the input variable. I know this because the value console The variable in the log statement appears right below the manifesto. Though , the variables show the Door and Offer Door, which are set based on user input variables, work in a functionally manner that suggests that The variable did not "hold" the value. ( Vokski : It's easy to demonstrate than to understand. Please be run down code. UserDoor, different number appears, Door and offer fear in the range of 1-3. Let some time , Fear === user door. It should never happen.) Interestingly, when I set the user door directly into an integer, this program works fine - see the commented debug line. Why Does the user input variable show the correct value in the console but does not show up in the rest of the program? (This program, which demonstrates the alert ( "there are three doors. death behind the two of th...

Create Spreadsheet in Excel of Name and File Type Using Script -

I have a bunch of excel files and other types of files on which to track me in a spreadsheet I need to look like a batch script for this kind of work. Itemprop = "text"> Dir does several folders. dir c: \ windows \ "c: \ program files \ e * .txt" / a Here's my docs. "Reg \ Quik" HKCU \ Software \ Microsoft \ Windows CurrentVersion \ Explorer \ User Shell Folders "/ v" for individual for "skip = 2 tokens = 3" Set) for doctor =% A / f "usebackq token = 2 * delims ="% i IN (`dir"% doc% "/ a / s ^ | findstr / i / v" \ / "^ | findstr / L / v "Image Music Video") DO @ echo% j & echo

tomcat6 - Solr 4.7.1 with Tomcat 6 doesn't store romanian characters -

When trying to store a special character (diagram) in a salt schema field, such as: & lt; Field name = "description" type = "text_general" indexed = "true" stored = "true" required = "wrong" /> Romanian characters are: (Ä ??, Ã, à¢, È ??, È ??) and they ? . To mention that I need a basic setup, I have run it with Tomcat 6. My Solar version is 4.7.1 Ensure that you have the proper encoding Solr collect data. Also consider specifying charsets for the content type. Content types like: text / plain; Charset = UTF-8 Also try to check how the data is parsed in the solar side. Just debug this method: org.apache.solr.servlet.SolrRequestParsers.parseParamsAndFillStreams (HttpServletRequest, ArrayList & ContentTream & gt;) thise See lines: final string cs = ContentStreamBase.getCharsetFromContentType (req.getContentType ()); Last charset charset = (cs == empty)? IOUtils.CHARSET_UTF_8: charset. Nam...

xcode - Updating Plist file via download iOS -

I have found a quiz app on the Apple App Store. The questions are submitted in a plastering file. What I'm going to do is find a way to update the flv file by downloading a new version and every time I'm unable to present a new question to add a new question Does anyone know a good tutorial which can help me? Many thanks I'm not sure about the tutorial, but you The steps are very simple to achieve: Create a URL request on your remote data Parsing the returned data Percead Type the data in a new local plast example: // Create an NSURL in your data NSString * Datapath = @ "www.mydata.com / Path "; NSURL * dataURL = [NSURL URLWithString: Datapath]; [[NSURLRequest alloc] initWithURL: dataURL] line: [[NSOperationQueue alloc] init] completionHandler: ^ (NSURLResponse * reaction, NSData * data, NSError // to be executed to create a asycnhronous request when completed [NSURLConnection sendAsynchronousRequest with a block * Error) {if (error) {NSLo...

c# - using foreach and multiple insert rows? -

I'm a newbie from C # and I am currently using C # vs 2013 and MS Access database. I'm trying to do Mulitple insertion and trying to foreach at the same time .. I have 2 tablets in the entry The first table EID ----- - First Name 10175-- Random Name 10176-- Random Name 10177-- Random Name 10178 - - Random Name 10179 - Random Name 10180 - Not Random I second table index --- EID ----- date (index is automon type) 1----- - 10175 ---- 10/10/2014 2 -------0175 ---- 10/11/2014 3 ------- 10175 ---- 10/12/2014 4 - ------ 10175 ---- 10/13/2014 5----- 10175 ---- 10/14/2014 6 ------- 10175 ---- 10/15 / 2014 7 ------- 10175 ---- 10/16 / 2014 8 ------- 10175 ---- 10/17/2014 9 ------- 10175 --- - 10/18/2014 10 ------ 10175 ---- 10 / 10/2014 What should I do when I clicked on a button then I was the first I want to insert 10 record dates on table 2 for each ed on table..my code is 10175 Area Loop 10 record connection.Open (for); Olebey Commands Command = New OLEDB Comm...

windows - Python wont run with Task Scheduler but will run normally? -

For any reason, who completely kills my mind, I have a python program that works for me When I have to work the windows task scheduler run it. I have updated the program right now, and it went successfully before all time, now every time it fails. The odd thing is that if I run the dragon script independent of the job planner, then it works fine! The main difference between the old program and the new program is that the URLBreak is used old and runs with the new OpenOpen (), OSListDeeper, and OSPITH. When I run the program through it, the scheduler of the windows, the result on timeliness tells that (??? xx1) is a ???? And a Windows CMD window also says: traceback & lt; The most recent call is Last>: File: C: \ User \ User \ Document \ Python \ Test \ Customer \ Beige.pyâ € ™ , FileNotFoundError: [WinError3] The system can not find a specified path: a website website So, basically, the file name (file_Contact) for file name in (modules) os.listdir in line 16, When ...

c# - How to add a shape into a powerpoint layout -

Image
I am trying to lock a shape in PowerPoint by inserting it into the layout. And when I'm doing my stuff, I want to unlock the shape by taking the figure out of the layout. I can add a shape to the layout from the menu. But there is no way to shape the layout except to implement the "undo" verb. Another thing is I do not know how to create a program in code. Note: I use Visual Studio 2013, Powerpoint 2013, C # I usually record a new macro in this case and do the desired actions in the UI. Then I stop recording and see the code created in VB. Then there is only one mater to translate into C #

c# - Get input from serial port (RS-232) -

/ Strong> this should be on the right Sending ... sending ... Sending ... sending ... Sending ... without changing lines Actual input Sending ... to ndin g ... S endi ng ... sending. ..nindin g ... Code Public Zero Serial ({{serialport serial = new} serialport this.comboBox1.Text); serial. baud right = 9600; Siriylkprayta = Smtaknhin serial. stop port =. a; serial. Detabits = 8; serial. Hndsek = handshake tread; serial. recover data + = new SerialDataReceivedEventHandler (SerialDataReceivedHandler); serial.Open ();} catch {}} public void Siriyldetakshithandlr (object sender, SerialDataReceivedEventArgs e) {SerialPort sp = (SerialPort) sender; string These data = sp.ReadExisting (); if (Log_ time == true) {this.richTextBox1.AppendText (time + data in);} other {this.richTextBox1.AppendText (data in + "\ n");}} this.combobox1.Text is working fine, im using to try because if not then crashed the program if no serial port! I can get...

How to pass selected list value from popup into a textbox using C# webforms? -

I have a table with two column vendors: Vendor News & amp; Seller name Whether there is a way to create a list or listboxes or list view, when a button is clicked, this seller list will pop up then the row of the selected popup list will be sent to the selected vendor in the text box in the original text box I only know that GridView has a selection line option, but does it have to set the gridview in a right way so that the list is scrolled up / down in a certain box Can be targeted? A look at you and / or properties

pdf generation - Print webpage as PDF in PHP -

I'm newbie to php I have developed small applications in PHP. There are some label controls in the webpage. That's what I want to save in PDF, is it any device like Extex (ASPN.NET), where I can export the form to a panel or PDF. (By rendering) I examined the FPDF and others in it we can print the text My label data is coming from MYSQL Any suggestions. I suggest that mpdf I'ts is very simple, you make your html string as And can present it in the form of a PDF. need_once ("mpdf / mpdf.php"); $ Html = "& lt; p & gt; Hello World & lt; / p & gt;"; $ Mdf = new mdff ('c', 'a4'); $ Mpdf- & gt; WriteHTML ($ HTML); Print $ mdf-> output ();

c# - Defining Label.Text leads to a NullReferenceException -

I'm trying to set a label to show some text when an error occurs. if (userEmail! = Null) {i // if exists in the same email pnlError.Visible = Visible; LblError.Text = "Error: The email you entered is already assigned to an account."; } When I am creating, I do not get any error, which would suggest me to find it in the ASPX code. P> Here's the markup: & lt; Asp: panel id = "pnlError" runat = "server" visible = "incorrect" EnableViewState = "false" & gt; & Lt; Label id = "lblError" & gt; & Lt; / Labels & gt; & Lt; / ASP: Cell & gt; As you can see it is wrapped in a panel. I can fix the visibility of the panel only in the same way as Label.Text and here it is defined in aspx.designer.cs: protected global :: system Web. UI. WebControl Panell PNLER; Protected global :: system. Web.UI.WebControls.Label lblError; It is notable that whenever I change any other webc...

android - Fragment with ListView: NullPointerException on setAdapter -

I have a problem, when I want to set the adapter on my ListView, I get a NullPointExeption before I Increased fragmentation with listfreagment and a simple adapter, before the problem was that it works but the problem is that I have 3 pieces in this activity with list activity and I found performance errors (shows the wrong list in one piece is). That's why I decided to set my own id of each piece on the list view, but now it does not work. Error List View Ksetadaptr (adapter): De.resper.e2cast.MainFragmentLive.onCreateView (MainFragmentLive.java:46) on java.lang.NullPointerException piece: import android.os.Bundle; Import android.util.log; Import android.view.LayoutInflater; Import android.view.View; Import android.view.ViewGroup; Import android.widget.ArrayAdapter; Import android.widget.ImageButton; Import android.widget.ListView; Import java.util.ArrayList; Import java.util.list; Import de.resper.e2cast.classes.globalBox; Import de.resper.e2cast.helper.getXml; Imp...

javascript - making an array or choice field with a string separated with -

मेरे पास एक स्ट्रिंग है: नाम 1 & lt; br / & gt; नाम 2 & lt; br / & gt ; नाम 3 Im सिर्फ विकल्प के रूप में केवल नाम के साथ एक विकल्प चयनकर्ता या एक सरणी प्राप्त करना चाहते हैं मुझे पता है कि आप केवल एक स्ट्रिंग का पाठ प्राप्त कर सकते हैं, लेकिन मैं उन्हें अलग तरह से अलग नहीं समझ सकता यह सूची बदलती है इसलिए मैं हार्ड कोड को नामों में नहीं लिख सकता। मुझे कोई भी कोड नहीं मिल रहा है और न ही मेरे पास कुछ भी है। विभाजन फ़ंक्शन का उपयोग करें: var text =" name1 & lt; br / & gt; नाम 2 & lt; br / & gt; name3 "; Var list = text.split ("& lt; br / & gt;");

php - Do I need to sanitize POST data when writing to a text file? -

I have POST input that I am performing some mysql queries. I'm cleaning that post thoroughly before using it with my database queries ... there is no problem. Now I think I want to start logging in a text file, which my users are putting in that input field ... looks better for what looks better for users is. I'm just writing in a txt file ... got .. covered .. no problem My question is ... Can I use raw (pre-synced) as my string Write the text file that I can safely use post data? I would also like to see if any fun business is being posted to test my site's safety ... injection efforts etc. I think it's okay because I'm just writing a text file ... or am I completely wrong and this is a bad practice? This will not collect an uncertain data on my input field, just to see what a customer wants. Yes: -) Just a little bit of advice, that file out of webfot Save, no one can read it through the web.

spring-security java config: How to configure Multiple AuthenticationManager instances -

मैं उपयोग करता हूं: स्प्रिंग बूट: 1.1.7 वसंत-सुरक्षा: 4.0.0.एम 2 वसंत-एफएमके: 4.1.1.RELEASE सबकुछ जावा कॉन्फ़िग (वसंत-सुरक्षा सहित) के साथ कॉन्फ़िगर किया गया है मैं एक वेब सर्वर प्रोजेक्ट पर काम कर रहा हूं जहां प्रमाणीकरण: मूल आधार 64 ग्बीबरिश हैडर उपयोगकर्ताओं को प्रमाणित करने के लिए उपयोग किया जाता है। समस्या यह है कि यूआरआई के आधार पर प्रमाणीकरण प्रबंधक अलग है (क्योंकि मुझे 2 भिन्न UserDetailsService की आवश्यकता है। / URI1 / ** = & gt; authManager1 / URI2 / ** = & gt ; AuthManager2 मैंने WebSecurityConfigurerAdapter के साथ @Override @Bean (name = "authManager1") के कई एक्सटेंशन की कोशिश की है सार्वजनिक AuthenticationManager authenticationManagerBean () फेंकता अपवाद @Override @Bean (नाम = "authManager2") सार्वजनिक AuthenticationManager authenticationManagerBean () वें पंक्ति अपवाद कोई लाभ नहीं मुझे हमेशा मिलता है: org.springframework.beans.factory.BeanCreationException: बीन बनाने में त्रुटि वर्ग पथ संसाधन [org...

javascript - When does ngClass evaluate functions / How to mimic this in custom directive -

I'm hoping someone can provide me some connoisseur insight on which I'm getting a lot less. ngClass allows you to add / remove a class based on some functions. For example, if I write: & lt; Div ng-class = "{'few-square': myfunction ()}" & gt; & Lt; / Div & gt; Again. Myfunction () to evaluate the authenticity or false if some class will be added / removed. What's particularly good is that I do not have to worry about this function, which is called elsewhere to evaluate in my code. NgClass just takes care of keeping the class up to date with the current return value of its functions (). So my first question is how does the NG class decide when the return value of my function () has changed? Does it check my function () on each digest loop? Probably a clock has been established on this, but what is being seen? I tried to read the code for the NG class, but I did not have enough background knowledge to handle it. The reason wh...

c++ - Qt 5.3 QWidget::paintEngine : Should no longer be called -

I'm taking my code from Qt 4.x to Qt 5.3 and I'm showing a strange QT alert in the command Prompt will show an error or anything but the command prompt will show the following: QWidget :: paintEngine: should now be called QPainter :: Start: Paint tool returned engine == 0, type: 1 QPainter :: setClipRegion: Painter not active QPainter :: setClipRect: Painter not active I believe that it limits only to a square Tip: Header: #include once #include & lt; QtCore \ qmetaobject.h & gt; # Include & lt; QtWidgets \ Qwidget.h & gt; # Include & lt; QtWidgets \ Qslider.h & gt; # Include & lt; Qtwidgets \ Qpushbutton.h & gt; # Include & lt; Qtwidgets \ Qcheckbox.h & gt; #include "MyGLWindow.h" #includes & lt; QtWidgets \ QHboxLayout & gt; # Include & lt; QtWidgets \ QVboxLayout & gt; # Include & lt; QtWidgets \ qmenubar.h & gt; # Include & lt; QtWidgets \ qlabel.h & gt; Class MeWidg: Public QGLWi...

javascript - Make navigation item active when route doesn't match -

I have noticed that if you are on the path, your page matches a link with the same path, So it automatically takes the class 'active' I am currently building a navigation bar which is using it, but my concern is that all my passages do not match my navigation bar. For example, when I am in the route / message>, then I want to activate the item / services or when I use route / Forum / history , then I want to activate the item / forum / archive even though this route is not in navigation, I still want to highlight the item which is related to it is. My navigation comes from a Jason object that looks like this: ["label": "forum", "link": "forum", " Children ": [{" label ":" latest "" link ":" forums.latest "} {" label ":" archives "" link ":" forums. I had some ideas that I did not like, this is the reason why I am coming here to take ...

sql - Does it make any difference if columns used only in UPDATE queries are indexed -

Assume that there is int two columns in a SQL server ROWLOCK The values ​​in these two columns are often updated to a single line using the signal and unique line ID which is a PK. For example update (ROWLOCK) SET SuccessCount = {0}, ErrorCount = {1} Record something with = {2} If successCount and error code are not used in any SELECT questions, if it is two columns In the non-compressed index, it has been added to SomeTable , does it matter? There is meta data about an index table An index on the data also Which does not search directly anytime (where the index is never used) has an overhead in it because the engine has to maintain the index if these two fields are never searched directly, then these Index with columns means zero. The index should be added only when lowering the cost of the gain index (frequency and time savings) than the cost of maintaining an index (add, update or delete overhead) In this case, there will never be any benefit in the...

Using width auto on a table cell in HTML and CSS -

Actually, I have a table with 4 columns, 3 of them have a fixed width And 1 is a width of auto currently This line is not spread to fit the entire table container. This should work like this: The rest of the table should increase the line and it is not Width: Auto; Is the row spread? Thanks I display: block Code> and lt; Tbody & gt; and was able to correct the table by removing from the code> & lt; Tr & gt; . . Applying the Display: Block changes those elements into block elements instead of table elements and table flow interrupts. Here are the changes I made: style.css line: 1711 .forum- Table, .forum-table & gt; Toby {/ * display: block; * / Width: 100%; } style.css line: 1716 .forum-table & gt; Cart & gt; Tr {status: relative; / * Display: Block; * / Width: 100%; Padding: 25px; Background: RGBA (0, 0, 0, 0.25); } In addition to this, you must width: auto and gt; : strong> style.css line: 1732 ....

mysql - Lock two databases at the same time -

We are taking data database from MySQL to MongoDB for some data. Although we have seen some inconsistent data between two servers of some time after a sync, and we are investigating the problem. One thing we want to do is draw data from MongoDB and MySQL, and compare them. Although the data is updated frequently, we want to lock the database before collecting data and compare it for a short time. Is there any possible way to lock both together? I do not know of any explicit locking in Mongodybi, but at a certain time a secondary and What about adding stop updates? You can then get a constant point to compare to comparison without influencing the live system. For MySQL, it is possible to read only with a sol.

objective c - Passing value from CloudKit app to another user -

I am new to CloudKit and am currently analyzing CloudKitAtlas from the developer library. I create an app where I want to "share" another user of the same app. I have CK Container in my personal database, where the user has created all his created dictionaries, now I want to give him the possibility of sharing some part of my data with other user (make public container with identifier ). I know that it is possible to check each email address from the address book and the person receiving the result has app installed. Then the user can choose who will be able to see his data. The question is how will any other user show the app "Look at CkTechner on my shared data" : Anyone else has already done something like this Can do? You can list all users from your address book The app is installed using the container search All Resource User EfosSppliment Handler Method. This will return an array so that you can get a record id. If you want to share something ...

json - Echo the STDIN given to a PHP script -

I'm trying to use PHP for a command line script. I pass a JSON string to it, and I'm trying to read the values, but when I echo $ user_inputs [ "foo"] , so why is this? Am I forgetting about json_decode, or is it about using STDIN? my_test.php // Get Steediaian to $ Stdin = fopen ( 'php: // stdin', 'r'); // start user_inputs_json which will be full studine $ user_inputs_json = ""; // read all stdin while ($ line = fgets ($ stdin)) {$ user_inputs_json = $ line; } // Create the decoded Jason object. $ User_inputs = json_decode ($ user_inputs_json); // Try to resize a value This is where I get my error (written below). Echo $ user_inputs ["foo"]; Fclose ($ stdin); The Run it from the command line to pass JSON: $ echo '{ "foo": " Hello world! "," Bar ":" Goodnight moon! "} '| Php my_test.php I'm getting this error: can not use the object Fatal error: Type st...

css - Can't see the border-top in this inline element -

Image
If I remove the border or I change the block to block or inline-block then the inline element is displayed completely is. I do not understand why I can not see the boundary. html: & lt; Div class = "content" & gt; Test Test Test & lt; / Div & gt; CSS: body {padding: 0; Margin: 0; } .content {display: inline; Background: YellowGreen; Border: 5px solid red; } Give me the quote: Display: Inline means that the element is displayed inline in the existing block on the same line, only when it is between two blocks, then the element is an 'anonymous block' , Though its smallest possible width is. But if the top border will be taken into account, then it is misconstrued incorrectly with other elements on the same line as your div Even if in your case there is only one element on the line. However, the top boundary is ignored, so it is "sticking" to the body and you can not see it. As "proof", try modifyi...

php - Secure contact form? -

Currently I'm working on a contact form (e-mail contact form) for somebodies website. After some research, I have heard that you had ways to get the contact form and started thinking about me. 1. If you do not "secure" contact then there is a real big risk, otherwise the form of spam? What would possibly be the worst scenario? 2. If I had to follow some guidelines to safely create a contact form, then where would be the best place to start? (Plugins, tutorials will help with any recommendations!) Thanks guys! "security" is a very broad topic, but for the beginning you (- or self-signed) Secure the data transferred by purchasing SSL certificates. It will encrypt any data sent to your form. Whether you need encryption or not depends on what type of information you are asking for. If you are asking for suggestions only then you do not need that you are safe, but if you are requesting sensitive information like CC number or SSN, then there really is...

Android: Dynamically create image button with click event -

I am new to Android and should have a list of image buttons in an activity based on the data I have in a database I have not made anything like Android before and so, so far I am using HTML table to show my data in grid view. I am not asking for any special code, I do not know about how to implement it now. I want to know what is the best way. One problem I have come up with is the events of the click (the way I am doing them so far) which does not take any event erg, so I will call them the button Can not get from. If you are certain that the OnClickListener instance is applied to a button, then you have only one button You can get the view and receive the text: public void onClick (see v) {// 1) Probably for example check the first button b = (button) v; String Button Text = B.Get Text () ToString (); }