Posts

Showing posts from August, 2011

bootstrap switch without text-label -

Image
I use the bootstrap switch without the white space ( data-text-label ) in the middle Wanted both data-on-label and data-of-label both options. And maybe I was going to solve it but I should go to other goods due to the dead line for the project. If someone knows I am very happy to know how to achieve it and share it with me. I am answering your question and putting it to assist future visitors I am here. label width: 0 main child Div width: 200 width: 50% .

css - Vertical align of div -

I am trying to create a simple html / css graph, in which to separate the bars for more than 0 values And there are smaller prices than 0. It looks like this: And I'm stuck with the vertical alignment of the top division focusing from the bottom so I need the div with the class bar class, class graph_top Can someone help me in that? I looked at some tutorials but I could not find anything that worked with percentages in terms of width for width. Image explanation: Here is the code: HTML & lt; Div class = "graph" & gt; & Lt; Div class = "graph_top" & gt; & Lt; div class = "lol" & gt; & Lt; div class = "bar" style = "height: 1px;" & Gt; & Lt; / Div & gt; & Lt; Div class = "bar" style = "height: 11px;" & Gt; & Lt; / Div & gt; & Lt; / Div & gt; & Lt; / Div & gt; & Lt; Div class = "horizontal_line" & gt; &

logout - Devise is giving me a routing error when logging out. Rails 4 -

For some reason I can not log out of the division, it does not keep any path error in me. Ensure that destroy_user_session_path is a removal method, your logout link should look like this: < pre> & lt;% = link_to destroy_user_session_path, method :: delete% & gt; Also, make sure that you have this application inside. Js: // required jquery_ujs

javascript - How to restructure object to array of objects? -

मेरे पास यह ऑब्जेक्ट है var डेटा = {_id: 131233442543, SocialMedia_0__Name_: "facebook ", सोशल मीडिया_डब्लूURL_:" http://facebook.com/test ", सोशल मीडिया_आ_नाम_:" ट्विटर ", सोशलमीडिया_1__URL_:" http://twitter.com/test ", सोशलमीडिया_1398083781749__ नाम:" लिंक किया गया ", सोशलमीडिया_1398083781749__URL_:" http: // linkin .com / test "}; और मुझे ऑब्जेक्ट को इस तरह से पुनर्गठन करने की आवश्यकता है: justSites = [{नाम: "facebook", url: "http: // facebook.com/test "}, {नाम:" ट्विटर ", यूआरएल:" http://twitter.com/test "}, {नाम:" लिंक्डइन ", यूआरएल:" http://linkedin.com/test " }]; इसे ऐसा करना चाहिए: var justSites = [], मी; ({नाम: डेटा [पी], यूआरएल: डेटा ["सोशलमीडिया _" + एम [1] +) [पेज पर] (माई = पी। मैच (/ सोशलमेडिया _ (\ d +) __ नाम / /) "__URL_"]});

python - syncdb error using mysql -

(im ji python2.7.6 पर django 1.6) मैंने एक ऐप कॉल साइनअप बना दिया है django, जब मैं sqlite इस्तेमाल किया था मुझे Python manage.py syncdb करने में कोई समस्या नहीं थी लेकिन अब यह है कि mysql का उपयोग कर मैं यह संदेश प्राप्त करता हूं: ट्रेसबैक (सबसे हाल की कॉल अंतिम): फ़ाइल "प्रबंधित करें" पीई ", लाइन 10, में & lt; मॉड्यूल & gt; execute_from_command_line (sys.argv) फ़ाइल "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", पंक्ति 399, execute_from_command_line उपयोगिता में। execute () फ़ाइल "/ usr / स्थानीय /lib/python2.7/dist-packages/django/core/management/__init__.py ", लाइन 392, स्वयं में निष्पादित करें। fetch_command (उप आदेश)। run_from_argv (self.argv) फ़ाइल" / usr / local / lib / python2 .7 / dist-packages / django / core / प्रबंधन / base.py ", पंक्ति 242, run_from_argv self.execute में (* आर्ग्स, ** विकल्प .__ dict__) फ़ाइल" /usr/local/lib/python2.7/dist -packages / django / core / managemen

jquery - issue with get array values outside the function in javascript? -

I have created an array that will store dynamic values ​​coming from DB. When I print the array inside the transaction function it is printing when I tried to print the side and I could not get the price. I have declared the array globally what is the problem, my code is as follows; function sendCategoryDetails () {var selected_category = $ ('# select-choice: selected'). Val (); Warning ("control:" + selected_category); Var mycoodinates description; Var myLocation = New Array (); Var db = window sqlite plugin.openDatabase ({name: "MYDB"}); db.transaction (function (tx) {tx.executeSql ("select location of location WHERE category = '" + selected_category + "';", [], function (tx, ridge) {for (var i = 0; i & lt; res.rows.length; i ++) {myLocation [i] = res.rows.item (i) .post;} alert (myLocation + "length:" + myLocation.length); // value print There is no value}}}}; alert (my position + "length:" + myLo

model - Rails : Custom Callbacks at Runtime? -

I am thinking that it is possible to make a model possible in rail with the custom callback code on runtime? I have a situation where I have many "nodes" that are making "events", and each node probably needs to run a specific callback on the event. For example, before a node can create an event, it may be necessary to call additional data on a third-party API, after creating a single event, the owner may need to send an email. In my head, when I do "POST / node / 4 / event", then it is understandable to set something like this: class nodes :: event controller & Lt; ApplicationController def # ... security checks are given place and if we have @ node if @node.requers_custom_callbacks? Load the file with callback for # @ Node.id, #node4 event extensions like some # event models, finally apply the node 4 avenue extension. End End End This node-specific code allows my event model, and I create / test different custom node extensions. Is th

python - Running rbtimer from emperor -

I have a web application managed by a monarch and two separate vassals. Because they both write in different data sources, I need to synchronize both a file and that's why I decided to add a timer job to my emperor. To: [ uwsgi] strict = true die -on-term = true memory-report = true uid = www-data gid = www-data emperor = xxx.ini logdate = true import = synchronize and It is synchronized .i : import from uwsgidecorators import rbtimer, lock INTERVAL = 10 @lock @rbtimer (INTERVAL) def synchronize (): "" "synchronizes data between Redis and PostgreSQL Land. " "Print 'aaa' I run my emperor in this way: uwsgi --ini emperor.ini But nothing happens, the console 'AAA' 'Never print. What else am I missing? You need a process (a worker or mule)) A worker to run the signal handler (Adding socket directive) or adding a mule (twisted = true) In case of mule you need to add target = mules to @ rbtimer decorator)

File not being written to in vb.net -

I have searched some Google and everyone gives me the same answer which is not working. I hope I'm remembering some of its simplicity. I am trying to write a line in the test file. The file was created properly when I used the same code, and if no error has been thrown, the txt does not write / save the file I stream in VB Here's my code using the author: Importing the system. IO Public Class Form 1 Private All BTNGG2DirectClick (as the sender in the form of the object, and event as ARG) handles BTNGN2DRAA Try 'This file has been created and protected from where it was saved: file = string as string = "c: \ users \ clint \ save.txt" if file. Example (fileLoc) then use SW as a new string (fileLoc) sw. ("Write a Test Line") sw.Close () end if the Android MSBbox (Expanded in the "C ++ 2D array text file:" + file lock, MSBbox style. Oak, "Successful"), using Expand MSBBX ("Error:" + E. Toaster (): MSBbox style. OK, "

jquery - Jssor (nested slider): how to disable AutoPlay? -

Do anyone know how to stop nested sliders from starting on loading? I have tried entering "$ Autoplay: wrong" inside "Weight NestedSlider Options", but it does not work Thanks in advance. Source: Example- jquery & gt; Nested-slider. Source.html There is no 'auto play' for the main slider and 3 kids By default, the sliders are handled by the manual API call. By removing the following code, you will be able to get whatever you want. Function OnMainSliderPark (current index, indland) {$ .each (nested slider, function (index, nested sledder) {nested sledger. Pause ();}); Set Timeout (function () (nested slider [current index]. $ Play ();}, 2000);} at Jssor_slider1. $ ($ JssorSlider $. $ EVT_PARK, OnMainSliderPark); OnMainSliderPark (0, 0); In addition, there is a variation of the nested slider.

css selectors - CSS rule for two class names provided in spaces for the class attribute -

मेरे पास extjs में एक बटन घटक है इस घटक सीएसएस के लिए class = 'one btn-exit-cls तीन चार पाँच x-menu-active' जैसा सेट किया गया है। उस वर्ग नाम btn-exit-cls अद्वितीय है जब इस बटन पर क्लिक किया जाता है एक मेनू दिखाई देता है जो सीएसएस वर्ग का नाम x-menu-active वर्ग को जोड़ता है मैं चाहता था btn-exit-cls और x-menu-active दोनों के संयोजन के लिए नियम सेट करें ताकि मैं विभिन्न बटनों के लिए मेनू सक्रिय शैली को लागू कर सकूं। मुझे क्या उम्मीद है .btn-exit-cls .x-menu-active {// कुछ Css} .btn-delete-cls .x-menu-active {// कुछ सीएसएस} .btn-add-cls .x-menu-active {// कुछ सीएसएस} I मौजूदा सीएसएस को संशोधित नहीं करना चाहता। मैं सिर्फ ओवरराइड करना चाहता हूं। यदि आप उन तत्वों को लक्षित करना चाहते हैं जिनमें दोनों कक्षाएं, आपको उनके बीच एक स्थान के बिना लिखना चाहिए: .btn-exit-cls.x-menu-active {...} अन्यथा, यदि आप इसे इस तरह wirte: .btn-exit-cls .x-menu-active {...} आप कर रहे हैं कक्षा x-menu-active के साथ लक्ष्यीकरण तत्व जो कक्षा btn-exit-cls

google admin sdk - How Do I Retrieve a List of Users Who Has includeInGlobalAddressList set to false? -

I am looking for a way to recover all the users in my domain which includes InGlobalAddressList = false what the value of the API Is there any way to do this? I do not think this is a way to do this via API, the complete list of searchable query attributes , And is not included in the InGlobalAddressList is one of them.

junit - How to run Selenium webdriver script in mulitple browser without changing parameters - java -

I want to run my WebDrive script only once after running the same in more than one browser I am In my current framework, I have placed all the browser names in the properties file and from there I am receiving it and passing through it as a parameter. But the problem is this way, in one execution it runs only for one browser. If I want to run it in another browser, then I have to give another browser name for another execution. I want to run it once and execute the script for a browser, after which it should also run automatically for other browsers. I'm using junit. How can I get it? Take a look at Selenyun or you can create a test site and use the system properties set on. Something like this: 1- Create a test site with all the exams import org.junit.runner.RunWith; Import org.junit.runners.Suite; Import org.junit.runners.Suite.SuiteClasses; @Ravivith (suite category) @ suite classes ({MyClassTest.class, MySecondClassTest.class}) Public class alstays {} 2- Run

R in quantmod error -

x = read.csv (file.choose ()) सिर (x) दिनांक खुली उच्च कम बंद खंड 1 2013/1/2 13257 13289 13162 13194 168353 2 2013/1/3 13195 13198 13055 13055 242457 3 2013/1/4 13050 13100 13005 13079 256215 4 2013/1 / 7 13085 13128 13025 13126 228488 5 2013/1/8 13136 13148 13064 13088 227064 6 2013/1/9 13091 13104 13044 13072 21 9 862 पुस्तकालय (quantmod) आप इसे एक पंक्ति में कर सकते हैं। जासूस & lt; -as.xts (read.zoo ("~ /") आपके डेटा लोड हो रहा है, यह मानते हुए "आपके डेटा" निर्देशिका में "spy.csv" नामक है, SP500 OHLC डेटा। डेटा / spy.csv ", हैडर = TRUE, sep =", ", colClasses = c (" दिनांक ", प्रतिनिधि (" संख्यात्मक ", 4))) बारचार्ट (SPY) आप सभी को इसकी महिमा में चार्ट दिखाएंगे: -)

Clear cookies on closing browser in php codeigniter -

Image
I am using a php codeigniter to create a larger application where I have different log in options for users of different levels have to give. And I've done a lot with everything when the user closes the browser so I want to clear all the cookies and sessions. how can I do this. Below is a very basic session set in the /application/config/config.php file. To set $ config ['sess_expire_on_close'] = TRUE; You

php - Symfony Forms - Is it possible to create a single entity from two forms? -

I understand that you can embed the form in some other form. UserCoreType: Username , password , email UserPersonalType: I want to do this with a registration form, which included both of these types, and I only provide personal information I want to create another form to update (i.e. not really a new look, just use UserPersonalType) I try to create 2 different user entities How can I do it for each form? I need to build a unit. OR How can I restrict the field? If I had to create just one user type, how can I make it so that the unit can be built earlier? For registration form simply enter UserPersonalType in UserCoreType Embed and use individual UserPersonalType to update personal information. UPDATE You can also use a single form for registration and updated information. Some fields use PRE_SET_DATA on the EventListener to read only.

vb.net - parse an xml file without changing the encoding and preserving the file format -

मूल xml फाइल को UTF-8 बिना एओएम के साथ एन्कोड किया गया है & lt;? Xml संस्करण = "1.0" एन्कोडिंग = "यूटीएफ -8"? & Gt; & LT; some_text & gt; & LT; ada / & gt; & LT; फ़ाइल / & gt; & Lt; title & gt; & lt; [CDATA []] & gt; & lt; / title & gt; & LT; कोड / & gt; & LT; parathrhseis / & gt; & Lt; / some_text & gt; मैं इस फ़ंक्शन में शीर्षक में पाठ सेट करने का प्रयास करता हूं: मंद myXmlDocument के रूप में XmlDocument = New XmlDocument () मंद नोड जैसा कि XmlNode Dim as String s = "name.xml" यदि System.IO.File.Exists (s) = False फिर गलत असफल समाप्त करें यदि MyXmlDocument.Load (s) नोड = myXmlDocument.DocumentElement नोड में प्रत्येक नोड के लिए प्रयास करें। ChildNodes अगर नोड। नाम = "शीर्षक" तब नोड। प्रथम चावल। इनरटेक्स्ट = "टेक्स्ट" अंत के लिए बाहर निकलें यदि अगला myXmlDocument.Save (एस) अपवाद MsgBox के रूप में पकड़ें ("एक्सएमएलपीर्सिंग में त्रुटि:&q

c# - EF 5 cast a ICollection into another -

I have a component that accepts two types of data sources Public Interface Ia .. Icons & lt; Ib & gt; Expansion {Received; Set; }} Public Interface IB {....} Then I have two EF classes that implement the interface Public class B: IB { } And my problem here is how to expand MyDetail in MyDetail by expanding and expanding, I use MyDetail for detail in the public class a: Ia {public virtual Ichlanack & lt; B & gt; MyDetail {get; set;} // How to expand MyDetal to detail and expand on MyDetail / some public virtual Icicle & lt; Ib & gt; Expansion {get {return MyDetail;} set {MyDetail = value}}}} Is that correct? Is there another incomplete for this conversation? You can not do this Icoding is not coherent, so you can Icon ; As Icoding Ib & gt; (in the recipient), and can not treat the nutrients, so you can the icon Icoding B & gt; (in setter) can not be treated. Icoding & lt; T & gt; is irreversible (Note tha

extract customers with same hobbies with mysql query -

customer IDs | Hobbies I would like to use mysql query to remove those who have the same hobby. If anyone has more hobbies then we have a line for every hobby. > It is easy to use Select customers from customer where hobby = 'football' My problem is that I Want to find hobby. For example ' football ' and ' swimming ' and the query should contain only customers who have both. Is it possible to do this with query or should I use the stored procedure and how? Select the customer from the customer, where the number of 'amateur' ('swimming', 'football') is in the customer's name.

java - parse json array in android -

I need a help ... I have a php file which gives me two Jason Array which are as follows: {"id": "1", "item": "hammers", "corridor": "20"} {"id": "1", "item": "hammers" "corridor": "20 "}] [{" Id ":" 1 "," itemfound ":" your item #item "," thank you: ":" And thanks for using Texaco! " }] Now, I want to get second array items in Android. I have the following code that is now like: JSONArray jsonArray = New JSONArray (Results); for (int i = 0; i & lt; jsonArray.length (); i ++) {JSONObject jsonObject = JsonArray.getJSONObject (i); Items.add (jsonObject.getString ("item")); Aisles.add ("" + jsonObject.getString ("item");} But obviously, it gives me the object from the first array. I want to get the objects from the other Any suggestion. Your JSON is not valid, b

encoding - Why is the output of the linux bash64 command different than other encoders? -

If I run the command echo 1234 | base64 , I get back to MTIzNAo = . If I input a string into other encoders (for example), I get different MTIzNA == . I see a similar pattern with the difference between the encoder. Both outputs look very similar, but differences from the last or the last to the last character are different. echo 12345678 | Base 64 Output MTIzNDU2NzgK , but I found MTIzNDU2Nzg = on base64encode.org, nodejs also as an encoder of base 64 encoder Returns the output, so I'm assuming this is not true in how Linux is using the base64 command. What is the difference? Because there is a new line: alex @ galene ~ $ Echo -n 1234 | base64 MTIzNA ==

c# - Why can my lambda expressions not use the same internal variable? -

I'm new to C # and it was working with lambda values. My question is why does the parameter list not have the same variable in each of them? If you do note in print (q is variable) and in square (there is variable in c) and there are variables in add (x, y) and in ISL constanten (f variable is) what if i want to make them all the parameter The name, such as pizza can be done. It was on the tutorial I was looking at My second case is that if you make better code instead of using regular functions? I think this is called Lambda Expression. I heard some different names on the tutorial video. Question: Can only one variable be used in different lambda signage? I want to know if I can say that use all the variable symbols in my lambda expressions verb & lt; Int & gt; Print = index = & gt; Console.WriteLine (index); Code: Action & lt; Bool & gt; Print = q = & gt; Console.WriteLine (Q); Funk & lt; Double, double & gt; Class = c = &

php - Save value as other table value -

I have an HTML form that saves all entered values ​​in SQL database, one of the options drawn by the database Dropdown menu is there. I want a way to save the population option because this is the user ID number instead of a readable name. There is another column in the ID number entry is currently using it to populate the dropdown: $ sql = "select site by name"; $ Result = mysql_query ($ sql); Echo "& lt; select name = 'venuename' & gt;"; While ($ line = mysql_fetch_array ($ result)) {resonant "& lt; option value = '" $ line [' name '] "' & gt;" . $ Line ['name'] "& lt; / option & gt;"; } Resonate "& lt; / select & gt;"; Get the id ID value attribute. $ sql = "SELECT id, name by name"; $ Result = mysql_query ($ sql); Echo "& lt; select name = 'venuename' & gt;"; While ($ line = mysql_fetch_assoc ($ result

cross browser - Same Origin Policy and subdomains -

क्या http://acme.help.com और http: // acme .com समान मूल के रूप में माना जा सकता है? क्या यह कुछ प्रतिबंधों में आ जाएगा? हाँ, यह विफल हो जाएगा मूल के मूल विचार के क्रम में, उनकी योजना, होस्ट और पोर्ट को मिलना चाहिए। यहां कुछ उदाहरण दिए गए हैं:

sql - Alternative to like/ like any?... regexp? -

I have a terabyte dataset that looks like the following: Customer_ID | Targeting_pradesh 12 | Targ = EU, targ =! Eu.Fr 34 | Targ = Asia 56 | targ =! EU '!' Means 'not equal' for example, in line # 1, the client wants to target the European Union, but wants to exclude France. I want to create a region that has flag (with '1') in any row where 'positive' targeting is. From 'positive' targeting, I am mentioning any row where clearly there is a specific area ('negative' targeting will be where a sector is clarified, such as boycott of France in Row # 1) For example, Line # 1 includes both positive and negative targeting, line # 2 includes only positive targeting, only negative targeting included in line # 3 Is. The problem is facing that a simple matter statement will not work (as far as I can tell) I have tried two statements below: ( When target_region is like '% targ =%', then 1 and 0 end) as the target_ flag (when

c++ - What's the quickest way to return the contents of a webpage in Qt? -

So, I'm trying to run some simple code in QT to return the contents of a given web page I am After a quick research, I was able to develop my own class to simplify the process: WebFetch :: WebFetch () = New QNetworkAccessManager (this); Connect (name, signal (end (QN network code *)), this, slot (Finish (QN NetworkCar * *)); } QString WebFetch :: get (QString url) {nam- & gt; Get (QNetworkRequest (QUrl (url))); } Zero WebFetch :: Finish (QNetworkReply * Answer) {QByteArray Data = Answer-> readAll (); Cue string straw (data); } However, I have a big problem with the code above that the call is asynchronous; I will prefer the "get" function to return the string only after receiving it, But it seems impossible that he has to wait for the finished signal, there is no way to "get" at that point which retrieves anything that has an option for the above method by the "finished" slot. Or am Is there any way that I can receive "to bring ba

java - Is Classic Spring MVC Deprecated? -

I am trying to figure out how to use the classic MVC controller (eg, et al.) The only thing I have found is only a part of using the material with an Alpeas (...). Still, I have not seen the boycott notice in Jawadok. The classic spring MVC usage is officially demoted? What version is this version from? and its subclasses have been removed from Spring 3.0 in favor of annotation-based controllers.

fontawesome icons with twitter-bootstrap-rails doesn't show on staging environment -

Railway (3.1.2) Twitter-Bootstrap-Rail (2.2.8) application with gem. In the app views, Font uses a terrific icon in Application.css.scss @import "bootstrap_and_overrides"; bootstrap_and_overrides.css.less @import "twitter / bootstrap / bootstrap"; @ Import "twitter / bootstrap / responsive"; // Set the perfect phantom path @ScienceStrite Path: Image-URL ("Twitter / Bootstrap / Glyphikon-Deadling Page"); @ConviteSriet Path: Image-URL ("Twitter / Bootstrap / Glyphicon-Deadlly-White-Pen"); // set Font Awesome (Font Awesome is default.You can deactivate by commenting below the lines) @ fontwebsitepath: property-url ("fontweather-webfont.ot"); @ Fontwavesetpath_ifix: property-url ("fontawesome-webfont.eot? #iefix"); @FontViewWebFace: Asset-URL ("fontawesome-webfont.woff"); @ Font ahompatiti path: asset-url ("fontoose-webfonts.ttf"); @ Font assists swing path: asset-url ("fontawesome-web

php - full path to upload files to server -

I am getting an error while uploading the file I uploaded the file that uploads the file The problem is that I'm calling it with a different file and different folders, which means that my folder on which the image folder is changing. WARNING: move_uploaded_file (http: // localhost) (I have the folder name - "pictures / user files") /dogger/images/usersFiles/13981072220-1.jpg) [function.move-uploaded-file]: failed to open the stream: HTTP wrapping in the \ "programming program (x86) \ wamp \ www \ dogger Does not support: 127: Warning: move_uploaded_file () [function.move-uploaded-file]: 'C: \ Program Files (x86) \ wamp \ tmp \ php9D89.tmp' to 'Unable to move to http: http : // func \ func.global.php: //localhost/dogger/images/usersFiles/13981072220-1.jpg 'In: \ Program I'm running a code from my local computer (x86) \ wamp \ www \ dogger \ func \ func.global.php on line 127 : if ($ _SERVER ['REMOTE_ADDR'] == "127.0

What is the ontology of UML? -

I'm curious to know what is UML's otology? diagrams, etc. Or things like organization, aggregation, structure etc ...? I tried googling but the answers were very ambiguous. How is it ... a systematic concept of a concept is the concept of UML software elements ( Those things you say). Use Case Diagram is a concept of the functionality of the system. An association is a concept of relations between 2 pieces of code, etc. From this, I would think that UML is the specificity otology, it describes all the purposes and uses of elements of UML.

javascript - Ember.js: Using an ArrayController without a route? -

I have a list of categories that I would like to display on the page. I have been looking for hours to walk properly, but I find conflicting information and methods that are either not working or dislike with the current version of Amber. The app and amber-data item to create: var app = amber Apps .create (); App.ApplicationAdapter = DS.FixtureAdapter; App.Store = DS.Store.extend ({adapter: 'DS.FixtureAdapter'}); I am using amber-data with data for some categories: App.Category.FIXTURES = [{id: 1, name: category 1 ', details:' first class'}, {id: 2, name: 'category2', description: 'second category'}]; Then I made a model to present an example of a category ("version" relates to a different model, where examples of the category are examples of the examples): App.Category = DS.Model.extend ({versions: DS.hasMany ('version'), name: DS.attr ('string'), Description: DS.attr ('string') }); Then I ha

x11 - Touchscreen Kivy app for Raspberry Pi -

Here is the scenario: I've written a GUI using the python framework, and I want to run it on a raspberry pie with the Are there. I have done the installation well, and TSLIB_FBDEVICE = / dev / FB1 TSLIB_TSDEVICE = / dev / Input / Touchscreen FrameBuffer = / dev / FB1 nohup startx & amp; The xwindow desktop GUI is running fine. I am unable to work my Kiwi Gui, though. I was able to get a test tkinter application working fine by setting the display environment variable. I tried to enter the following at the top of my kivy app, but there was no profit: os.environ ['SDL_VIDEODRIVER'] = 'fbcon' os. Whenever I run my application, this debug output is: / code> [info] [logger] /home/pi/.kivy/logs/kivy_14-04-21_10.txt [info] people in these Kivy v1.8.1-Dev [information] [Python] v2.7.3 (default, March 18, 2014, 05:13:23) [GCC 4.6.3] [information] [Factory] loaded with 157 symbols [information] [image] Rider: img_tex, img_dds, img_pygame, img_gif

c# - Code to Determine if FTP Directory Exists Suddenly Stopped Working -

I wrote the following code for a long time to determine whether an FTP directory exists: Public Child Directory Axis (String Directory) {try {FtpWebRequest Request = GetRequest (Directory); request. Method = WebRequestMethods.Ftp.List directory; (FtpWebResponse response = FtpWebResponse) as request.GetResponse () {StreamReader sr = New StreamReader (response.GetResponseStream (), System.Text.Encoding.ASCII); Sr.ReadToEnd (); sr.Close (); Response.Close (); } Back true; } Hold {} return false; } Secure FtpWebRequest GetRequest (string file name = "") {FtpWebRequest request = WebRequest.Create (_host.GetUrl (filename)) as FtpWebRequest; request. Authentication = new network credentials (username, password); request. Proxy = faucet; request. KeepAlive = false; Return request; } This code has worked for many years, but today it is not so. When testing a directory that does not exist, the code DirectoryExists () now throws an exception, and returns the method incorrect

security - Rails has_secure_password: is it actually hashing the password in the DB? -

has_secure_password के साथ विशिष्ट रेल 4.1 ऐप का उपयोग कर और उपयोगकर्ता मॉडल में है डीबी में एक password_digest कॉलम जब मैं एक नया उपयोगकर्ता बनाऊँ, तो मैं अब भी कंसोल में सादा पाठ का उपयोग कर सकता हूं: # rails console & gt; यू = यूज़र। न्यू (ईमेल: "test@test.com", पासवर्ड: "पासवर्ड") & gt; u.save & gt; u.password = & gt; "पासवर्ड" & gt; u.password_digest = & gt; "Xjdk ..." हालांकि, जब मैं कंसोल सत्र को बंद करता हूं और एक नया प्रारंभ करता हूं, तब मैं सादा पाठ प्राप्त नहीं कर सकता: # कंसोल सत्र के ऊपर बंद करें और एक नया खाता खोलें & gt; u = User.find_by (ईमेल: "test@test.com") & gt; u.password = & gt; शून्य मैं मान रहा हूँ कि सादा पाठ पासवर्ड केवल पहले स्थिति में ही पुनर्प्राप्त करने योग्य है क्योंकि यह स्मृति में संग्रहीत किया जा रहा है और जब मैं कॉल करता हूं u.password = & gt; "पासवर्ड" यह मेमोरी से मान पुनर्प्राप्त कर रहा है, डाटाबेस नहीं है। मैंने हमेशा सोचा

codeigniter - How to combine and & or operators in grocery crud -

I am using codeigniter and grocerycrud, I want to set up table with grocerycrud like this: SELECT * FROM from `dashboard`. 'Medid_ludlum` where FK_ludlum =' 190.26.88.131 'and date & gt; = '2014-03-04 09:40:00' and date & lt; = '2014-03-05 09:40: 00' and (ErrorGode = 1 or Audio_Status = 1); I tried to do this: $ uno = '1'; $ crud2 = new grocery store (); $ Crud2- & gt; set_theme ('datatables'); $ Crud2- & gt; Where ('FK_ludlum', $ ludlum_id); $ Crud2- & gt; Where ('date & gt; =', $ fechainicio); $ crud2- & gt; Where ('date & lt; =', $ fechafin); $ crud2- & gt; Where ('error_code =', $ uno); $ crud2- & gt; Or_where ('audio_status =', $ uno); $ Crud2- & gt; set_table ('medidas_ludlum'); $ Crud2- & gt; Column ('measurement', 'fecha', 'audio_status', 'high_alarm_status', 'low_alarm_status', 'over

python - Importing Turtle graphics modules -

I believe I have just started Python 3.3 in turtle graphics, and Started with a YouTube presentation from to Turtle Import * . This allows at least the commands as FD (100) instead of the format I turtle.forward (100) etc. My questions are: Am I using an unacceptable shortcut using this format? How can I stop Python IDL from interpreting every command in this format as "Turtle Graphics"? "*" What does suffix mean, as is "everything"? If I should not ask many questions in a post, I apologize in advance, but they are relevant to each other and it seems logical. Normally, yes, you can avoid using the form from the module import * It does this that opens this module (a normal python file), and basically takes every function, class etc. defined in that file and adds it to your namespace. And you are right - * means "everything". Therefore, if I wrote a module named foo.py which contained the function named bar 1 ,

r - Plotting the overlay using an exponential smoothing of a time-series using `lines()` -

Image
/ * I do not want to use R in the HoltWinters function, and I have used Holtwinters function But I really do not want to apply or copy the entire R code. Mainly I want to write a code, as a result we get the answer given by Holtwinters * * I have the following code so far, but I'm not sure which function I should use 1 An exponential lubricating data (nhtemp) required for New Hampshire from 9 to 12, 1971 and the lines () Plot overlay .ts (nhtemp) lines (nhtemp, col = "red") # plot.ts (nhtemp) to the same plot Gives it in the form !! I'm not sure how to overlay an exponential solubility of PS by using nhtemp lines () I do not want to try an forecast or statistics such as an external package, but I was trying the following for some experiments: I followed the instructions given in the following picture Tried but I found this error: & gt; Line (nhtemp $ fitted) Error in # lines (nhtemp $ fitted): Error in evaluating argument 'X' in

javascript - Common model in ExtJs 4 -

one ???? I have a few grids that have the same fields, I want to create a normal model and extend it from below: Ext.define ('my.model.MyModel', {extend : 'Ext.data.Model', field: [{name: 'fieldA'}, {name: 'fieldB'}]}); Ext.define ('my.model.MyModelA', * Expand: 'my.model.MyModel', Field: [[// How do I add extra columns to sub-class?}]}); And also for the grid. Just add additional fields. The model will be detected during the definition time. Ext.define ('A', expand: 'Ext.data.Model', field: ['name']}); Ext.define ('B', {extension: 'a', field: ['age']}); console.log (B.getFields ());

django - Restrict access to a Class Based View based on the request user and view to be rendered -

यहाँ दृश्य है: प्रोफाइल / models.py क्लास यूज़रप्रोफ़ाइल (models.Model): user = models.OneToOneField (उपयोगकर्ता, प्राइमरी_की = सच) जन्मदिन = मॉडल.डेटाइमफिल्ड (रिक्त = सच) def __unicode __ (स्व): वापसी यूनिकोड (स्वयं। यूजर) श्रेणी विशेषप्रोफ़ाइल (models.Model) : user = models.OneToOneField (उपयोगकर्ता, primary_key = true) ... # अतिरिक्त फ़ील्ड यहाँ def __unicode __ (स्वयं): वापसी यूनिकोड (स्व। ऊस्टर) वर्ग विशेषप्रोफाइल URL (models.Model): profile = models.OneToOneField (SpecialProfile, primary_key = सच) ... # कुछ और यूआरएल मुखपृष्ठ_उर्ल = मॉडल। URLField (रिक्त = सच) def __unicode __ (स्वयं): वापसी यूनिकोड (self.profile) वर्ग विशेषप्रोफाइल छवियाँ (models.Model): profile = models.OneToOneField (विशेषप्रोफ़ाइल, प्राथमिक_की = सच =) img1 = models.ImageField (रिक्त = सच, upload_to = 'प्रोफाइल /') img2 = models.ImageField (रिक्त = सच, upload_to = 'प्रोफाइल /') img3 = models.ImageField (रिक्त = सच, upload_to = ' प्रोफाइल / ') def __unicode __ (स्वयं) : Publicic

sql - How to use the exists operator properly in mysql? -

I want the EXISTS operator to list client names that do not have an order So, I have two tables (as shown below), a designated customer who holds the customer name and customer ID and the other designated orders that hold the customer ID as well as the order ID. I Customer ID using Customer, Select Customer ID, Order Order from Order Where Order ID & lt; & Gt; Customer ID); But the way I wanted it is not working. In a way you can do that EXISTS syntax privately, it makes more sense to me I think this query will work for you: Choose customer name, Customer ID to customer C, where no one is from (order from where order from C.CustomerId = O.CustomerId)

list in python behaviour -

I have a list that lists my_list mylist = [[]] * 5 Now I want to add an integer to 4 from the third list in my_list my_list [2] .append (4) When I print My_list, I see that integer 4 has been added to each list in my_list. & gt; & Gt; & Gt; My_list = [[]] * 5 & gt; & Gt; & Gt; My_list [2] .append (4) & gt; & Gt; & Gt; My_list [[4], [4], [4], [4], [4]] there is one Just the way to add 4 to the third list? Expected: [[], [], [4], [], []] Actual: [[4] ], [4], [4], [4], [4]] Find Answers my_list = [[]] I should do the move in xrange (5)]

python - Flask 500'ding and I'm not sure why -

I am trying to piece together a flask app to play with dragon and flask. It's got an avenger theme (how well is anyone watching that movie?!). Anyway, when I hit the / dashboard path, I get the benefit of 500 and I am not sure why take care to help me? Import flask.ext.sqlalchemy from flask, render_taglet, request, glitch, jsonify from flask import, SQLAlchemy app = flask (__name__) app.config.from_object ('config') db = SQLAlchemy (application) ## #################################### ## Category ticket (db.Model): id = db.Column (db.Integer, primary_key = true) email = db.Column (db.String (120), index = true) name = db.Column (Db.String (64), index = trojas) whatWentWrong = db.Column (db.String (5000)) def __repr __ (self): return "ticket" def __init __ (auto, email, name, whatWentWrong): self.email = email Self.name = name self.whatWentWrong = whatWentWrong ######################## @ app.r Oute ('/') @ app.route ('/ index') def activate_shi

java - Hibernate - What primary key should I use in a one to many relationship without an ID on the child table -

In a very simple way, I am trying to create the following structure: Post ID (pk) name content table tag post_id (name to post id) the name so that a post can have several tags, but the tag does not have a primary ID. (The primary key so far will be the overall post_ID + name) Now what I want to know is that it is bad behavior (leaving the id column in the tag table) and what happens when using hibernate Potential value to use as the primary key for the tag table. In a normalized, every line in the database has a primary key; it should be post_id feels like a foreign key that should refer to the table of the post id primary key. I do not care much for this design; There may be many tags in a post; A tag can be applied to several posts, it should be several-to-many designs with the host table. Create a table post (id int do not auto_interment, text varchar (140), primary key ID); Create table tag (id int null auto_increment, name varchar (80) not tap, prima

SQL Server 2000 - How to remove the hidden characters in the column? -

Image
I'm trying to remove a hidden letters from the varchar column, these hidden characters (I.e. period, location) was taken from a scan bar code and after the query was executed it is not visible in the result set. I have tried to use the script below, but it failed to delete the hidden characters (see attached screenshots for reference.) Any help is highly appreciated < MyTable from serialno = '123456789' Img src = "https://i.stack.imgur.com/MvCzk.jpg" alt = "Enter image details here"> One thing that has worked for me is with columns, special characters, then data Paste in Notepad ++ then see & gt; Show Icons & gt; Show all characters, then I can copy the special characters of Notepad ++ in the copy () function in SQL in the second argument.

edit mysql table with php -

I'm missing something and I need some help! Creates a table with the code editing field below. When I edit the fields, this data sends the data to my editing page which will run an updated script. But when I press the update button on any line, it sends every record in the loop. How can I limit the record which I have chosen to update? Thank you for your help! $ sitequery = "SELECT *" like the WHERE address with the meter data '% $ site%' by the order 'alias + 0 "; $ Siteresult = mysqli_query ($ connection, $ sitecorruption); Echo "& form; form action = 'editmeter.php' method = 'get' & gt;"; $ Resultstring = '& lt; Table class = "table-table-hover"> gt; $ Resultstring = '& Lt; Tr & gt; '; $ Resultstring = '& Lt; Th & gt; Apartment & lt; / Th> '; $ resultstring = '& Lt; Th & gt; Address & lt; / Th> '; $ Resultstring = '& L

When is using public fields acceptable Java -

I have a main square with thread pool, which is used by some other classes to perform actions on the database. goes . I currently get a great method to get the pool which works fine, but something looks weird Is there a situation where it is acceptable to use any public sector instead of gater / setter methods? Is there a situation where it is used to make use of public sector rather than gater / setter methods Is Acceptable for? The main reason is that the public sector is bad, they display the implementation in the outside world, there is an unwanted coupling; That is, classes which are more dependent on the details of implementation of other classes. To understand this, the code makes it difficult and it is difficult to change. And if the area is not the last , then you have to find the entire code-base to make sure that there is nothing "interference" with that field. (OK, IDE makes it easy ... but compare a public area with a private area with no setter

c++ - How can i create a class that inherits the methods from FILE -

How do I increase the FILE class to use my methods? In other words, how can I use all the tasks that are provided with the default FILE object and still have the same functionality that imitates the actual functions? class myFile {file * _f; Public: Open MyFile (File * F) {/ * file here, then _f = f; * /}; Virtual ~ myFile () {/ * Close the file here}; // and add more methods here}

NoMethodError in Articles#edit in Ruby on Rails tutorial section 5.11 -

इस तरह से बाहर निकलें: Ubuntu 12.04 64 बिट, रुबी 2.0.0, रेल 4.1.0 < P> मैं आधिकारिक रुबी ऑन रेल ट्यूटोरियल () का पालन करने की कोशिश कर रहा हूं, लेकिन मैं धारा 5.11 में फंस रहा हूं। मैंने लोगों को 5.12 से परेशान किया है, लेकिन 5.11 नहीं, इसलिए मुझे लगा कि मुझे पूछना चाहिए। यह वह हिस्सा है जहां वे आपको एक फ़ाइल को संपादित करने का तरीका बताते हैं। अब, जैसा कि उन्होंने कहा है, मेरे edit.html। एआरबी फ़ाइल के लिए: & lt; h1 & gt; संपादन आलेख & lt; / h1 & gt; & Lt;% = form_for: आलेख, url: articles_path (@article), विधि:: पैच करना | f | & Gt%; & Lt;% if @ article.errors.any? & Gt%; & Lt; div id = "error_explanation" & gt; & lt; h2 & gt; & lt;% = बहुवचन (@ article.errors.count, "त्रुटि")% & gt; इस लेख को सहेजने से प्रतिबंधित किया गया: & lt; / h2 & gt; & LT; ul & gt; & lt;% @ article.errors.full_messages.each do | msg | | & Gt%; & Lt; li & gt; & lt;% = msg% & gt; &am

d - multiplying a string by an integer returns integers? -

So I was trying to create asterisk pyramid using D. At first I saw that the combination seems impossible. Writing something like writeln ("foo" + "bar") will give you a syntax error. Instead, I tried to multiply the string like a dragon, which did not work with double quoted strings, But there is something strange with single quoted stars. If you type in import std.stdio; Zero main () {foreach (i; 0 .. 10) {article (i * '0'); }} This will return a bunch of integers. Can anyone explain why this happens? And to tell me how to add a string, it really will be helpful. Thank you! '0' is not a string, it is a character that uses ASCII encoding. The number is being multiplied with the integer ID of the encoding. For example, encoding for ASCII's 'A' is 65. import std.stdio; Int main () {writeln (cast ('a'); Written (10 * 'A'); Return 0; } This program will print 65 and 650 because the character is being

Emacs mode line shows AC is on but no autocomplete is happening -

मैंने ताजा इंस्टॉल किया है स्वतः पूर्ण पॉपअप और एएल-एनआरपीएल एल्पा से जब मैं emacs में एक क्लोज़र बफर दर्ज करता हूँ, तो एसी इंगित करता है कि स्वतः पूर्ण चालू है। लेकिन बफर में मैं जो भी लिखता हूं या करता हूं, मैं कुछ भी करने के लिए स्वत: पूर्ण नहीं मिल सकता। I'v थोड़ी देर के लिए इस समस्या का निवारण कर रहा था, किसी भी संकेत? मेरे पास यह भी मेरे emacs स्टार्टअप में है: (ऐड-टू-लिस्ट 'लोड-पथ' ~ / .emacs.d ") ('स्वत: पूर्ण-कॉन्फिग' की आवश्यकता है) (एसी (एप-हुक 'सीडर-रिप-मोड-हुक' एसी-एनआरईपी-सेटअप) (एड-हुक 'साइडर- मोड-हुक 'एसी-एनरिप-सेटअप) (eval-after-load "auto-complete"' (ऐड-टू-लिस्ट 'एसी-मोड' साइडर-रिप-मोड)) (सेट अप-ऑटो-पूर्ण- पूरा-से-बिंदु-फ़ंक्शन () (setq पूर्णता-पर-बिंदु-फ़ंक्शंस '(स्वत: पूर्ण))) (ऐड-हुक' ऑटो-पूर्ण-मोड-हुक 'सेट-ऑटो-पूर्ण-पूर्ण-पूर्ण-पर -पैंट-फ़ंक्शन) (ऐड-हुक 'साइडर-रिप-मोड-हुक' सेट-ऑटो-पूर्ण-के-पूरा-पूरा-बिंदु-फ़ंक्शन) (ऐड-हुक 'साइडर-मोड-हुक' सेट-ऑटो-पूर्ण को

c# - Type safety of indexed columns in an in-memory database -

Root of the problem: I want to design a database entry member indexing API, for which the model definition does not require repetition and maintenance. A fair level of security of type. Dry Out-Explanation: I have a basic memory database of people in the table, the full name of each person and the key to their favorite celebrity. Public class IMDB {public dictionary & lt; Int, person & gt; People; } Public class person {public string first name; Public string last name; Public int favorites celebrity id; } Now the celebrities want to be able to find their fans quickly through favorite celebrity ID . An index is clear, and thinking for the future, I created this interface: public class IMDB {public dictionary & lt; Int, person & gt; People; Private dictionary & lt; Object, dictionary & lt; int, int & gt; & Gt; _rowContents; Private dictionary & lt; Object, dictionary & lt; Int, list & lt; Int & gt; & Gt; & Gt; _rowI

vb.net - vb net backgroundworker + progress bar -

I want to automatically create the progress bar which will pop up when I ran my program .. My program has 6 functions / sub which takes a considerable amount of time to complete the running query, it is input It is about 1-2 minutes for the backgroundworker to handle the thread and to combine it with the progress bar RunWorkerAsync Personal Sub ButtonX1_Click (ByVal Handle ButtonX1.Click) as the System.Object, as byVal e System.EventArgs. Click BackgroundWorker1.WorkerReportsProgress = True BackgroundWorker1.RunWorkerAsync () End Sub Do_work Private sub BackgroundWorker1_DoWork (ByVal as the object, byVal e System.ComponentModel.DoWorkEventArgs ) 100000000 i as integer = 0 to create_tree handles for BackgroundWorker1.DoWork () localtree () Localfrek () create_combination () showresult () if I mo d 10000000 again background 1. Report progress (i / 100) end if the next ending sub progress progress 1_ProgressChanged by Private sub background (ByVa

php - Writting query in Yii -

इस सवाल का पहले से ही एक उत्तर है: < / P> 3 जवाब मेरे पास निम्न प्रश्न हैं। ..और मौजूदा क्वेरी में कुछ संयुक्त अतिरिक्त संयुक्त बयानों को जोड़ना चाहते हैं ... प्लेन एसक्यूएल क्वेरी पोस्ट करना ताकि यह मुझे पता चले कि मैं वास्तव में क्या देख रहा हूं। / * साधारण एसक्यूएल क्वेरी * / SELECT * से Job_profile उपयोगकर्ता पर उपयोगकर्ता को जुड़ें user.id = job_profile.user_id INNER पर श्रेणी दर्ज करें श्रेणी.id = job_profile.category_id जहां श्रेणी_id = 1 और अनुभव = 2 और key_skills '% php%' की तरह LIMIT 0, 30 / * सरल एसक्यूएल क्वेरी * / मैंने अभी तक चलने की कोशिश की है। और अब तक इसका कामकाज ठीक है ... लेकिन मुझे नहीं पता कि संयुक्त वक्तव्य कैसे जोड़ना है। $ results = SearchEmployee :: मॉडल () - & gt; findAll ("category_id =: श्रेणी और key_skills जैसे: कौशल और अनुभव =: अनुभव", सरणी ('ca तकनीक '= & gt; $ श्रेणी,' कौशल '= & gt;'% '। कौशल'% ',' अनुभव '= & gt; $ अनुभव)); मैं सिर्फ उपर्युक्त बयान र

PHP - Maximum size allowed for each element of array -

In my program, I have 12 multi-dimensional arrays, which vary in size between 200-7000, in each cell of the array There is a float number with precision (such as 0.0000000000000123344) and these arrays pass values ​​to each other for some calculations. At some time I get an error of memory loss in some arrays (I have changed all the configuration related to memory and This maximum stop It is). I am thinking that what is the maximum size to store float in a large array? Thank you. Finally I can find a solution I found that when the PHP collection is being loaded, There is no way to free it. Unset and gc_collect_cycles () are also not effective The only way to use the ** function ** on a separate section of code is in my case , I had a large script for loop , so I copied all of my code into the function, and I call the function in my loop. Every time the function quiets, the memory becomes free. You can test it once in your work by adding memory_get_usage () and see th