Posts

Showing posts from March, 2011

android - How to initialize TypeFace in an interface class -

तो मेरे पास यह इंटरफ़ेस है: सार्वजनिक इंटरफेस Utils {static final typeface font = textface .createFromAsset (getAssets (), "फोंट / फ़ॉन्ट.टीटीएफ") ;; } मुझे getAssets () में एक त्रुटि हो रही है, यह कहता है विधि getAssets () प्रकार Utils के लिए अनिर्धारित है क्यों क्या वह? कृपया मदद करें धन्यवाद:) आपका Utils वर्ग में कोई विधि नहीं है getAssets () । मुझे लगता है कि आप एंड्रॉइड context वर्ग से एक का उपयोग करना चाहते हैं I इसका मतलब है कि आपको संदर्भ ऑब्जेक्ट कॉल करने की आवश्यकता है getAssets () । आपके सटीक ऐप डिज़ाइन के बारे में अधिक जानकारी के बिना, मैं आपकी सहायता नहीं कर सकता। एक संभावित समाधान एक गतिविधि उपवर्ग बनाना है जो आपके सभी अन्य गतिविधियों का विस्तार करते हैं। आपको जीवन चक्र की गतिविधि का भी सम्मान करना होगा: सार्वजनिक अमूर्त फ़ॉन्टएक्टिविटी गतिविधि को बढ़ाता है (निजी टाइपफ़ॉर्म फोंट; @ ओवरराइड पब्लिक ऑन क्रेट (बंडल सहेजे गए इन्स्टैंसस्टेट) {सुपर.नक्रेट (सहेजे गए इन्स्टेंसस्टेट); Font = Typeface.createFromAsset (getAssets (), "फ...

sql - How to count amount of data for each row -

मेरे पास यह तालिका है: आईडी का नाम 01 02 03 04 05 06 07 0000068 नाम 1 वी VX 0000069 नाम 2 वी VX VX VV 0000070 Name3 VVVVVV यह अनुपस्थिति की जांच के लिए एक तालिका है और मैं कॉलम 01 से 07 तक प्रत्येक पंक्ति से डेटा की मात्रा की गणना करना चाहता हूं, इसलिए मुझे उम्मीद है पहली पंक्ति 2 का परिणाम, दूसरी पंक्ति 5 और तीसरी पंक्ति 6 ​​देगा। और यदि संभव हो तो मुझे यह चाहिए कि नतीजा एक नया कॉलम के रूप में जोड़ा जाए क्या किसी भी तरह से काम करने का कोई तरीका है? यदि कॉलम की संख्या स्थिर है, तो आप सरल मामला अभिव्यक्ति। का चयन करें, मामला जब [01] = '' या [01] तब शून्य है 1 या 1 अंक + मामला जब [02] = '' या [02] नल तब है जब 1 ईएण्ड + मामला जब [03] = '' या [03] तब शून्य हो जाता है जब 1 या तो + मामला होता है जब [04] = '' या [04] तब शून्य होता है जब 1 ईडी + मामला तब [05] = '' या [05] है नल तब 1 या 1 ईडी + मामला है जब [06] = '' या [06] शून्य हो तो 1 या 1 + मामले का मामला है [07] = '' या [07] तालिका शून्य से 1 या तो [सीएनटी] नल है; ...

java - XA transaction for two phase commit -

Hi, If two resources are included in a transaction then the XA Transition setting should be weblogic The server should be enabled then the XA drivers should be turned down. This is an alternative way of transacting two resources without enabling the XA transaction Yes, you can use global transaction emulation. Weblogic has two modes: Logging Previous Resources - Weblogic creates a table in all your data sources and writes transaction data in this table. This is a preference option. From the official document: With this option, connection is used in transaction branch & gt; Transaction is processed as the final resource and in the form of a local transaction. & Gt; Record for two-step commit (2 pc) transactions is put into a table on record resources, and & gt; The result determines the success or failure of the prepared phase of the global transaction. & Gt; This option offers some performance benefits and two-step ambulatory & gt; Provides m...

c# - Identifying elements in Iframe after content change using Selenium -

problem I have an iframe that contains a form, Once upon a time, I present some of the content of the IFRM transformation on the basis of information. So I need to verify the results / elements as part of my test. What did I do I used the switch () is. The data for frame IFrame for submitting, and "WebDriveWit" is used to wait for the results (I'm waiting for one element) issue After submitting new elements Am I doing something and after time the "waiting element" fails, even if the result screen is visually impaired Are you loaded in IFrame wrong? Or can someone suggest me? I am working on the same scenario and for this To work, you can try: driver. SwitchTo (). Frame (frame); Driver.findElement (by.cssSelector ("input [name = \" login \ "]). Click (); // whatever you want to frame. Driver.switchTo () defaultContent (); Thread.Sleep (3000); driver.switchTo (frame). Driver.findElement (By.cssSelector ("Input [nam...

.htaccess - how to Change a GET method URL to clean URL in php? -

यह एक URL है जो gET विधि द्वारा php में बनाया गया है डेटा पैरामीटर को archives.html पृष्ठ भेज: http://127.0.0.1/archives.html?option=com_archive&diffate = 16-2-2014 क्या इस URL को साफ करने का कोई तरीका है? मुझे ऐसा कुछ करना है (और मैं भी पैरामीटर भी भेज सकता हूँ!) http://127.0.0.1/archives.html/16-2-2014 क्या मैं इसे mod_rewrite के द्वारा कर सकता हूं? (मैं जूमला 3 पर एक घटक विकसित कर रहा हूं) आप इस नियम को अपने रूट .htaccess में उपयोग कर सकते हैं: RewriteEngine On RewriteRule ^ (अभिलेखागार .html) / ([0-9 -] +) /? $ / $ 1 / विकल्प = com_archive और date = $ 2 [एल, एनसी, क्यूएसए ]

java - How to pass a List as parameter by using ActionForward? -

I am creating a simple project using Sturts 1.0 and Hibernate. The main task of the project is to take unit number from Welcome page and then query the database for information about the unit and show results on the Index.jsp page. Struts-config .xml & lt; Struts-config & gt; & Lt; Form beans & gt; & Lt; Form-bean name = "welcomeForm" type = "tutorial.truts.form.valcenform" /> & Lt; / Form-side & gt; & Lt; Action Mapping & gt; & Lt; Action Path = "/ ViewSetset" name = "welcomeform" type = "tutorial.Session. & Lt; forwarded name =" success "path =" / index.jsp "/> & gt; & lt; forward name =" failure "path = "/ Welcome Jsp "/> & lt; / action & gt; & lt; / action mapping & gt; public class extends viewAllAsset operation {@SuppressWarnings (" unused ") Public ActionForward executed (ActionMapping mapping, acti...

python - generate SEQUENCE on next day it will initialize using Psycopg -

Using PostgreSQL and Python We want to generate sequence based on daily basis as the next day begins with sequence 1. We are using the Tryton framework. Former: 201402170001 (Year 0001) Generates more than 100 sequences this day, next day it will start from 201402180001 . We produce the sequence but we do not know how it should be disabled on every next date? You can use datetime to get the date string .datetime.strftime and use the string string formatting for the pad for some enhancements counter for four digits: datetime from datetime counter = 1 ("% 1% 2" P> To update the counter daily, you will need to store the current day, then reset it to 1 when it changes, like: if current_date! = DatetimeToday ( ): Counter = 1 # recieve Counter Wartman_deta = Detataim

Dynamically add input to RapidMiner through Java -

I need dynamically input files in my Java application and have to use miter quickly for classification. I have the following code: RapidManer. Setexuation mode (RapidManor.excution mode.com); RapidMiner.init (); Process Process = New Process (New File ("C: \\ User \\ Nellz \\. RapidMiner 5 \ \ Repository \\ Walking Repo \\ NaiveClassify.rmp"); Operator op = processor. Operator ("read CSV"); Op.setParameter (com.rapidminer.operator.nio.CSVExampleSource.PARAMETER_CSV_FILE, "C: \\ User \\ Nell \\ Anilayed (2) .csv"); //ioInput.append(op); IOContainer ioResult = process.run (); ExampleSet resultSet1 = (ExampleSet) ioResult.getElementAt (0); Iterator & lt; Attribute & gt; AllAttributes = resultSet1.getAttributes (). AllAttributes (); However, when I run it, it's always called "not defined in the input file." In my RapidMiner process, the input port reader is connected to the CSV operator Any help would be appreciated I t...

javascript - pass input value from one form to another form at same jsp page -

I have two forms in my jsp page, the first form has an input value and the other form The button is submitted, I can not use both forms due to some issue. Now I want to access the first form value in another form . My sample code is here, & lt; Form name = "orange" id = "before" & gt; & Lt; Div & gt; & Lt; Input type = "article" name = "n1" & gt; & Lt; / Div & gt; & Lt; Select onchange = "document.forms ['onchange']. Submit ();" Name = "select" & gt; & Lt; Option value = "A" & gt; A & lt; / Options & gt; & Lt; Option value = "A" & gt; A & lt; / Options & gt; & Lt; / Form & gt; & Lt; Form action = "servlet" id = "seconds" & gt; & Lt; Input type = "submit" name = "sub" value = "submit" & gt; & Lt; / Form & gt; I need to access a firs...

ruby on rails - Cannot create new record in ActiveRecord -

I'm trying to move from Rail 3 to Rail 4. I do not know why, but when I new Trying to create a record I get the error message: 2 errors are restricted from saving this group: name can not be empty The tag can not be empty Here is a controller code: def @user = UserData.find_by_login (session [: cuser]) @group = @ u Ser.groups.new (params [: group]) "== puts =====================" P @user P parameter P parameter [: group] P @group P "========" P @user .groups response_to do | Format | If the @groups save form.html {redirect_to (@group ,: notice = & gt; 'The group was created successfully.')} Format.xml {render: xml = & gt; @ Group,: status = & gt; : Created: Location = & gt; @ Group} and format.html {Render: Action => "New"} format.xml {Render: xml = & gt; @ group. Errors,: Status = & gt; : Unprocessable_entity} End End End Here is a console log: ================= ====== As I have seen, we have a ...

sql - Get values from two data ranges and use this in a join? -

सेलेक्ट sh.Nr_V, tt.journalnumber, sh.journalnumber_end, sh.journalnumerstart से transactiontable टीएटी बायाँ जोन salesheader sh Sh.journalnumerstart और sh.journalnumber_end के बीच में टी.टी. उपरोक्त मेरा nr_V मेरे transactiontable पर शामिल होने के बारे में मेरा विचार दिखाता है। इसलिए मुझे Journalnumberstart और journalnumber_end और मेरे transactiontable में शामिल होने के लिए उनका उपयोग करें। यह संभव नहीं है कि मैं काम में शामिल हो सकूं! यह विचार है कि Nr_V से salesheader से मेरे transactiontable में शामिल हो जाता है - समस्या को journalnumber को देखना है दो स्तंभों के बीच की सीमा में सेल्सहैडर Nr_V जर्नलनंबर स्टार्ट जर्नलन्यूम्बरअंड 100 1001002 1003000 101 1003001 1004000 सेल्सट्रांस्कैक्शन journalnumber 1001004 1001005 1003032 आउटपूटटेबल Nr_V जर्नल नंबर 100 1001004 100 1001005 101 1003032 तो हम चाहते हैं कि SalesTeader और SalesHeader के बीच संबंध पाने के लिए बिक्री प्रमुख की श्रेणी में देखना चाहिए! कृपया याद रखें कि मेरे लेन-देन में ...

sql - How to get the data for the current week from MSSQL -

I wanted to know how I can get records of the current week. The query I am using is: DECLARE @TableX TABLE ([Date] DATETIME) Include @TableXSelect '2014-2-17 Select 'Union All' 2014-2-18 'Union All Substitutes' 2014-2-19' Union All Selection '2014-2-20' Union All Substitutes' 2014-2-21 'Select * SettleABADADATTIFF = DateDD (Day, DATEDIFF (DAY, 0, GETDATE ()) / 7 * 7, 0) and date & lt; = DATEADD (DAY, DATEDIFF (DAY, -1, GETDATE ()), 0) The query I wrote does not generate data correctly? Can anyone please tell me what is wrong in the query? The following are the records I received from this query: 2014-02-17 00: 00: 00.000 2014- 02-18 00: 00: 00.000 Please try to use CTE. According to the question given below, 7 days a week is considered 7 days a week. ; With t as (Select Date (wk, dethiff (wk, 0, getdate ()), -1) AS Weekday, 1 cnt unions all select week + 1, cnt + 1 to t WHERE cnt + 1 & lt; 8 ) Choose convert (NVHA...

objective c - Expandable UIView in ScrollView in iOS -

Image
How can I do my UIViews for Expandable / Compact UIView embedded in ScrollView. This is my main approach and when the user taps on the button, the view automatically changes (+200 height) And the ideas given below will automatically adjust it so that the scroll view Edit: I think I can not use TableView because I am creating an automation form like this So my idea is that whenever the switch is on, the label will be added to the parent's child The form of the trigger acts as the email form and the switch duties. There may be a modified version of the Aquarian view, you can get some ideas All the tableviews have a collection view on the ScrollView, so if you have the time then you can create the full functionality For yourself in four simple tasks: on a scrollView completely To attract external listings in the form of customizable views HandBlenfoExpandingUnteral Just: Decide to expand or stop the scene. Draw Innerlist: Scrollview Handlutenphone Expa...

xml - Fetching a particular value in XSL 1.0 -

& lt; साबुन: लिफाफा & gt; & LT; साबुन: हैडर & gt; & Lt; eb: मैसेजिंग ईबि: संस्करण = "3.0" आईडी = "ई-मेल मेसेज" साबुन: आवश्यक होना चाहिए = "1" & gt; & LT; EB: UserMessage & gt; & LT; EB: PartyInfo & gt; & LT; EB: से & gt; & LT; EB: PartyId / & gt; & LT; ईबी: भूमिका & gt; प्रेषक & lt; / ईबी: भूमिका & gt; & Lt; / EB: से & gt; & Lt; / EB: PartyInfo & gt; & Lt; / EB: UserMessage & gt; & Lt; / ईबी: संदेश & gt; & Lt; / साबुन: हैडर & gt; & LT; साबुन: शरीर & gt; & LT; रिस्पांस & gt; & LT; सीएसी: विक्रेता & gt; & LT; सीएसी: पार्टी & gt; & LT; सीएसी: PartyIdentification & gt; & LT; सीबीसी: आईडी & gt; 123412341234 & lt; / सीबीसी: आईडी & gt; & Lt; / सीएसी: PartyIdentification & gt; & Lt; / सीएसी: पार्टी & gt; & Lt; / सीएसी: विक्रेता & gt; & Lt; / प्रतिक्रिया & gt; ...

python find and replace new lines -

मेरे पास निम्न पाठ है: नाम: जॉन आयु: 23 स्थिति: एकल लिंग : पुरुष नाम: मीरी आयु: 19 लिंग: महिला का नाम: एलेक्स आयु: 20 स्थिति: एकल लिंग: पुरुष मैंने नीचे नोटपैड ++ का इस्तेमाल किया और प्रतिस्थापित किया ढूंढें: \ r \ n एगे: बदलें:! आयु; खोजें: \ r \ n स्थिति: बदलें:! स्थिति; खोजें: \ r \ n लिंग: प्रतिस्थापित करें:! लिंग; आउटपुट के लिए: नाम: जॉन! आयु; 23! स्थिति; एकल! लिंग; पुरुष नाम: मीरा! आयु! 1 9! लिंग क्या मैं इसे नोटपैड ++ अजगर स्क्रिप्ट की जगह लेता हूं और इसे बदलने के बजाय कैसे I कुछ संपादनों के साथ जुड़ने वाली लाइनों के लिए नीचे दिए गए कथन का उपयोग करें ?? editor.pyreplace (r "\ r $ \ n", "!", 0, Editor.INCLUDELINEENDINGS) \ r \ n (?! नाम) और ! ?

How do I close a server with socket.io (stop it from listening to a port) -

How can I turn off a listener which was opened with something like socket.io Was: io = require ('socket.io'). Listen (3333); and then in some time: io.closeListener () On the server side, you can: socket.disconnect ();

php - advantage of repository pattern in laravel against instantiating a model in a controller constructor -

दो उदाहरण लेते हैं। उदाहरण 1 ( रिपॉपीटरी पैटर्न ) इंटरफ़ेस इंटरफ़ेस FooInterface {सार्वजनिक फ़ंक्शन सभी (); } मॉडल (इसे एक ढीला अवधि में प्रयोग करना) वर्ग FooModel लागू करता है FooInterface {सार्वजनिक फ़ंक्शन सभी () {वापसी डीबी: :( 'sometable') - & gt; मिल (); }} सेवा प्रदाता वर्ग FooServiceProvider ServiceProvider विस्तारित {सार्वजनिक फ़ंक्शन रजिस्टर () {$ this- & gt; ऐप- & Gt; बाँध ('फू \ फ़ूइंटरफेस', 'फू' फू मोडेल '); } config / app.php 'प्रदाताओं' = & gt; सरणी (// - 'Foo \ FooServiceProvider'), और आखिरकार नियंत्रक : मॉडल के रूप में फू \ फ़ूइंटरफेस का उपयोग करें; सार्वजनिक फ़ंक्शन __ रचना (मॉडल $ मॉडल) {$ this- & gt; मॉडल = $ मॉडल; } अब मैं विधियों को $ this- & gt; मॉडल- & gt; सभी () के रूप में एक्सेस कर सकता हूं। यह बहुत अच्छा है! हम दूसरे उदाहरण को देखें। उदाहरण 2 : नियंत्रक : सार्वजनिक फ़ंक्शन __construct () {$ this - & gt; मॉडल = नया \ फ़ू ...

cordova/phonegap documentation confusion -

Cordova / PhoneGap documentation is very confusing to me, especially regarding iOS. For example: In this case: Orientation lets you prevent the interface from rotating in the orientation of the orientation and changes in the orientation. Possible values ​​are default, landscape, or image. Example: & lt; Priority name = "orientation" value = "scenario" /> That is not working at all. In addition to this, no plugin found I got the compilation (most files are missing). I feel that this is the issue of the edition, but none of the documents I have mentioned has not mentioned anything about it. So my question: How to lock orientation? How do I get the right documents? As the link I supply is '3.3.0' which means version, but I can not find the documentation for config xml in v2. 3.3 - In iOS - the setting is done by setting the locking * -info.plist: ; NOTE: You must delete unnecessary values ​​from the default gene...

Meteor Iron Router layout template -

It looks like a basic one but I can not get the iron router to render my template in the right place on the page. I have in my router controller: router. Configure ({loadingTemplate: 'loading', notFoundTemplate: 'notFound'}); Router.map (function () (this.route ('home', {path: '/', template: 'home', layout template: 'layout'}); this.route ('post', {}); In the layout HTML page I have: > & Lt; body & gt; & lt ;! - Some other static page stuff here - & gt; & lt; div class = "container" & gt; & gt; template name = "layout" & gt; {{generated }} The basic version of the Home Template looks like this: & lt; template name = "home"> gt; h1 & gt; main page Th I have tried some variation on this but the home template is always closing body tags instead of the design container The first layout is presented at the bottom of the template Yo...

ruby - Why does my `require` statement cause a LoadError? -

मैंने money मणि स्थापित किया है: $ मणि स्थापित धन सफलतापूर्वक स्थापित पैसा-6.0.1 1 मणि स्थापित पैसे के लिए री दस्तावेज़ीकरण -0.0.1 अधिष्ठापन ... पैसा 6.0.1 के लिए RDoc दस्तावेज स्थापित कर रहा है ... स्थापित करने के बाद , मैंने एक आईआरबी सत्र शुरू किया और इसे "पैसे" की आवश्यकता से लोड करने की कोशिश की, लेकिन मुझे LoadError मिला: LoadError: no ऐसी फ़ाइल को लोड करने के लिए (आईआरबी) से: 1: में से 'की आवश्यकता' से (आईआरबी): 1 इसके बाद भी क्यों LoadError मैंने सफलतापूर्वक मणि स्थापित किया है? आपके लोड पथ में कुछ गड़बड़ है आपको रूबी (rvm, rbenv, system?) को स्थापित करने के बारे में अपने प्रश्न के बारे में जानकारी जोड़ने की आवश्यकता है। इस बीच, यह आपको मणि के साथ काम करना शुरू कर दे, कम से कम: की आवश्यकता होती है (`मणि जो पैसा '। स्ट्रिप)

How to hide the animation of actionbar show and hide in android? -

Image
I have an activity in which tabhost is and I use several pieces for tabhost, only one piece in each tab , Which means that the piece size corresponds to the parent. However, there is no action bar in all sections For example, first hide an actionbase, while the other shows the action. The problem is, when I show / hide the work pane, it does not transacts instantly, but it is a nostalgic that for example to hide the case- & gt; Show, hide the actionbars and leave the space on the screen, then the content screen will be expanded to fit the screen. It creates some "glitch" in the UI, so is there a way to fix it? I tried requestWindowFeature (com.actionbarsherlock.view.Window.FEATURE_ACTION_BAR_OVERLâ ???? a) AI); Update: The overlay of the taskbar is the same as this screenshot, at the top of the content Please see Please see here one thing for here RequestWindowFeature (com.actionbarsherlock.view.Window.FEATURE_ACTION_BAR_OVERLâ ????AAAC AI); T...

php - Error xsl during installation propel_generator by pear -

I'm in install 1.7.0 via Wax in Pulp. Currently: PHP v 5.4.16 - libxslt v 1.1.27 - libxml v 2.7.8 - libxml2 v 2.7.6 Apache v. 2.4.4 Mikes v. 5.6 .12 log v. 1.12.7 ft v. 2.7.0 When you try to install propel_generator: Pear channels- Find pears .Propelom ORG Pears installed propell / propell_generator I get an error: requires a PHP extension for the propell / propell_generator "xsl" No valid packages were found Installed failed Someone tell me why? View active modulus xsl in phpinfo I found three config files: php: C : \ Wamp \ bin \ apache \ apache2.4.4 \ bin \ php.ini: extension = php_xsl.dll C: \ wamp \ Bin \ Php \ php5.4.16 \ php.ini: ; Extension = php_xsl.dll C: \ wamp \ bin \ php \ php5 4.16 \ phpForApache.ini: ; Extensions = php_xsl.dll Check out Active PHP extensions when in vom. Is this normal behavior? What should we do to make changes manually? Do these three files need the same version?

java - Out of Memory Exception while loading data into List -

I'm trying to generate a heatmap on a googlemap, about 2 million digits (latitude and longitude). My thoughts are to read the numbers from the table, and they have to give it to the Google API in the list. The problem is, loading the 2 million points in the list causes a memory error in EJB. The following is the line that gives me an error. list & gt; Earthquake & gt; Earthquake risklist = em.createNativeQuery ("Select as geomette (geomia), in the form of risks, Earthcomcers E from Eidcom", Earthquarkarsk. Class). GetResultList (); What options can be applied to read and load points in the map? I have glassfish 3.2.2, JDK 1.7, JSF 2.2, ezb. You can see: In addition, Have you thought about implementing your own? After this you can recover the required data on demand when the itater completes the next stage. Another option would be to split your dataset - like you want to score on the page.

json.net - How to parse attribute in JsonConvert.DeserializeObject -

We have followed JSON output from an API. We are using the following code in ASP.NET deserialize for a JSN response in a class: var j = JsonConvert.DeserializeObject & lt; Classname & gt; (reaction); While deserializing the following JSON, we are unable to get the attribute value. {"user": {"address": {"@CityName": "test", "$": "B4C99EB0-18E6-439F-882A-9E4A11E1FF75"}}} Please refer to us as the @ sitiname and $ attribute value. We require the following output in the class: @CityName: Test $: B4C99EB0-18E6- 439F-882A-9E4A11E1FF75 I'm getting element value, but I can not recognize the attribute value. Is there any way I can do that? You can use [JsonProperty] to map non-standard JSON You can use the name of the property for properties in your class to create your classes like this: Root object of public class {public user user {get; Set; }} Public class user {public address a...

mongodb - Not able to enable sharding -

I have deployed a sliced ​​cluster and when I am trying to enable misery, I get the error below Has been there. I tried to find an online solution, but unable to solve it. I did the following things to start Mongoode / Mongos and Mongo Instances mongod --configsvr - dbpath / data / config b - port 27018 mongos - configidib 127.0.0.17018 - Port 27019 Mongo - Config 127.0.0.17 9 9 In Maggot: mongos> ("Config") {"errmsg": "Exception: Claim Source / Mongo / s / config.cpp: 155", "Code": 0, "OK": 0} Besides, I am able to make a general collection here, but there is no fraudulent collocation. At the same time, I am not able to make general collections other than DB configuration mongos> Show DBS Admin (empty) Config 0.046875GB configdb (empty) Raghu (blank) Exam (empty) Mongos & gt; Mongos & gt; DB Test Maggot & gt; Mongos & gt; Sh.enableSharding ("test") {"ok": 0, "errmsg...

Pre-Order product Magento -

Is there a way to add custom styes in order of pre-order options set products? I have already explored the basic steps of adding product to order but my question is whether I added a rule to set a custom position in the pending pending order situation. Can - Preorder-date. / app / design / frontend / default / template / p / list / product / view / addtocart.phtml $ _ Product-> MillPreorder ()) {$ buttonTitle = $ this- & gt; __ ('pre-order'); } And {$ button titles = $ this- & gt; __ ('Add to Cart'); } Now in the item when the getPreorder is set, this product will add a custom note to the pre-order mode. Now the model / controller that has been set to Yes on Yes, the custom status is set to edit. Any help is greatly appreciated. You can add a new status without code Panel & gt; System & gt; Order Status The correct model for this is: $ orderStatusModel = Mage :: getModel ('Sales / Order_Status') - & gt;...

Why SQL Server DATETIME type saves time in ticks of 1/300 of a sec? -

The SQLServer datetime format is stored as 8 bytes, where 1 January 1900 and the second after the first four There is a number of four bytes, the number of bytes is very high by midnight and the tick is 1/300 of the second. I wonder why this is? Where is it that came from 1/300? There should be some historical reasons for this. Yes, there is a historical reason: Unix! For details, who read it by Celco. This is the information you are looking for: Temporal data in T-SQL is a Unix system clock tick and round errors With only three decimal seconds, the new ANSI / ISO data types can go up to seven decimal seconds, a correct date and time data type. Since they are new, most of the programmers are not using them.

hibernate - how to run servicemix 3.3.2 with spring 4 su component? -

यह देखना है कि सेवा मिश्रण 3.3.2 वसंत 4 + हाइबरनेट 4 ? कॉन्फिगरेशन की आवश्यकता क्या है? कृपया मदद करें सर्विस एमिक्स 3.3.x ईओएल है और यह स्प्रिंग 4 का समर्थन नहीं करता है।

c++ - How to generate static lib that contains all its dependencies? -

I am working on a project where we need to separate the mathematical routine of our application for an independent SDK The application, which will be consumed by another application. To avoid over the creation of export definitions, we thought about creating a static Lib. The point here is that these mathematical routines are dependent on other lbs, so the customer must also include them. My question is how can we create a static lib that has all dependencies? Let me assume that I am trying to create a static lib C1.lib which depends on D1.lib, D2.lib and D3.lib. Now a client application that requires the use of C1.lib, must also provide a list of D1, D2 and D3 as its dependency. Is it possible to do this also in Windows? How can this be done or why it can not be done but any explanation will really be helpful. If you select librarian & gt; Normal You can add d1.lib, d2.lib, and d3.lib under additional dependency . They will be added to your output lab

c++ - What is wrong with this code in string reversal? -

I get the error mentioned below in the following section of the code. Please tell me why * p = t returns an error here zero reverse (four * p) {int length = strlen (p); Int c = 0, i = length / 2; Char * Temp = p + length-1, t; While (c & lt; length) {t = * temp; * Temp = * p * p = t; // incorrectly in error, why is there a typed four * // line in the correct operator? C ++; Temp--; A semi-colon is missing: T = * Temporary; * Temp = * p; // - Here * p = t;

c# - TypeLoadException -

I am using an app.config file to store credentials and when I try to retrieve them , I have a TypeLoadException as follows: The 'System.Configuration.DictionarySectionHandler' type could not be loaded from the assembly System.Configuration, Version = 4.0.0.0, Culture = Neutral, PublicKeyToken = b03f5f7f11d50a3a ' This is a .NET 4.5 project, I have system and System.Configuration Copy-local attributes Magistrate therefore the true , and I do not understand what comes from where the problem is I have no experience in the NAT programming, so not very easily with the concept of assembly. & Lt; ConfigSections & gt; & Lt; Section group name = "credentials" & gt; & Lt; Section name = "Twitter" type = "System.Configuration.DictionarySectionHandler" /> & Lt; / SectionGroup & gt; & Lt; / ConfigSections & gt; & Lt; Credit & gt; & Lt; Twitter & gt; & Lt; Add key = ...

r - Plot margins for support vector machine -

I just set an SVM in R with e1071. Unfortunately the margin plot and the die-hyperplane do not look desired. I wanted to pass the margin to the support vector, should not this matter be? Can someone make my mistake? This is my code: rm (list = ls (all = TRUE)) x1s & lt; - c (.5,1, 1,2,3,3,5, 1,3,5,4,5,5,5,6) x2s & lt; - c (3.51,2.5,2,1,1.2, 5.8,3,4,5,4,1) Ys & lt; - c (Representative (+1), Representative (-1,6) my.data & lt; - data.frame (x1 = x1s, x2 = x2s, type = as.factor (ys)) my .data library ('e1071') svm.model & lt; - svm (type ~., Data = my.data, type = 'c-classification', kernel = 'linear', scale = FALSE) plot (my.data [, -3], col = (ys + 3) / 2, pch = 19, xlim = c (-1,6), ylim = c (-1,6)) digits (my.data [svm.model $ index, c (1,2)], col = "blue ", Cex = 2) w - T (svm.model $ coefs)% *% svm.model $ sv b & lt; - -svm.model $ rho p & lt; - svm.model $ sv abline (a = -b / w [1,2], b = -o [1,1] / w [1,2], col...

java - How to get hours and minutes from a String variable ? -

I have a string time . I was wondering how I would go best about getting hours and minutes and converting them into an integer i.e. int hours = 13, int minute = 10. I know that loop will not be the most effective way, Is anyone easy? In this way, try through the method, string Tym = "13:10"; String [] time = time Source (":"); Int time = intangible.center (time [0] .tem ()); Int min = intiar.press (time [1] .tim ());

python - What is the difference between pandas agg and apply function? -

I can not understand the difference between pandes .groupate and .apply functions. As an example below: I load a dataset, do a by group , define a simple function, and either user .gg or .apply . As you can see, the print statement .gg and .apply within my work. The result, on the other hand, is different why is it? PD iris = pd.read_csv ('iris.csv') by_species = iris.groupby ('species') import as DF F (x) Panda import pandes: ..: Print Type (x) ...: print x.head (3) ...: 1 return using : By_space.plie (F) # and Lt. Class 'panda.core.frame.frame'> # Sepal.Length Sepal.Width Petal.Length Petal.Width Species # 5.1 5.1 3.5 1.4 Setosa # 1 4.9 3.0 1.4 0.2 Setosa # 2 4.7 3.2 1.3 0.2 Setosa # & lt; Class 'pandas.core.frame.DataFrame' & gt; # Sepal.Length Sepal.Width Petal.Length Petal.Width Species # 5.1 5.1 3.5 1.4 Setosa # 1 4.9 3.0 1.4 0.2 Setosa # 2 4.7 3.2 1.3 0.2 Setosa # & lt; Class 'pandas.core.frame.DataFr...

mysql - Index changes with varchar values -

My query shows different varchar values ​​for different types of my table structure. table create `equipmentdata` (` EqpmDataDBId` int (11) NOT NULL AUTO_INCREMENT, `SerialNumber` double default '0',` ReadValue` boat default '0', `ReadTime` varchar ( 25) default zero, `DataType` varchar (100) default zero,` EquipmentDBId` int (11) default '0', `EquipmentCustomId` varchar (50) default zero,` LocationCustomId` varchar (50) default zero, `ChannelCustomId` varchar (50) default zero, `ChannelName` varchar (100) default zero,` IsUploaded` tinyint (1) default "0", pRIMARY KEY ( `EqpmDataDBId`), unique key` SerialNumber` ( `SerialNumber`,` EquipmentCustomId` , `LocationCustomId`,` ChannelCusto MId`), KEY `ReadTime` (` LocationCustomId`, `EquipmentCustomId`,` ChannelCustomId`, `ReadTime`), Kunji` SECONDARY` (` EqpmDataDBId`, `Sthankstmaidi`,` Upakrnkstmaidi` "Canlsistmaidi`)) engine = IndiBible Default Charge = UTF8; / *! 40101 SET character_set_cli...

ajax - Posting php multi dimentional array into a new window -

I have an associative array from my database. I would like to open a new window I have managed to post it in Ajax Post, but I do not need it because I want a new window! It is impossible to use a form because you can not keep that kind of data in hidden input. So how can I do this? I think that you PHP example: echo json_encode (array ('int' => 123, 'char' => 'abc', 'array' => array (1,2,3)); Javascript: $ GetJSON ("AJAX / Test. Php", function {data} {console.log (data); // data is a Jason-object data. Unit (function) {console.log (type.in item.int) // number, value 123 console.log (type item.char) // string, value '123' console.log (item of type. Array) // array / object, value 1,2,3})}} ; Edit : Name is selected as int, char and array as an example. >

java - Mysql Result set Error -

I am executing a block of code where I will retrieve a group of database users and some things with them need to. The very simple scenario is that although I am using (rsnext ()) , when rsnext () reaches the tap, continue with my program code Tries, while the segment and zero exits with the exception. Why is this happening? Is something broken in my code that I can not understand? Please note that RS never null initially prints all of the rs on the console, but when it reaches to the end So this gives an empty exception. try {string sql = "select specific userid from user information"; Stmt1 = conn.createStatement (); Try (result rs = stmt1.executeQuery (sql)) {while (rs.next ()) {string mentionsIDs = (rsgetstring ("mention")). Trim (); Try {if (! Mentionss.isEmpty ()) {System.out.println (mentionsIDs); String [] arr = mentionsIDs.split ("\\ s +"); If (numeric (ARR [0])) {System.out.println (AER [0]); Sources.add (Long.parseLong (Advent [...

java - EasyMock + PowerMock : How to mock field? -

हम कोड के इस टुकड़े को देखते हैं: सार्वजनिक वर्ग ए {सार्वजनिक शून्य doSmth ( ) {// pay attention - शून्य विधि // impl}} सार्वजनिक वर्ग बी {निजी ए a_instance; // रिक्त सार्वजनिक शून्य doSmthElse () {a_instance.doSmth (); // एनपीई यहाँ बिना नकली // भी smth करते हैं Else} अब, मेरे पास बी बी = नया बी () है; और मुझे b.doSmthElse () परीक्षण करना है , लेकिन मुझे पहले a_instance ऑब्जेक्ट के लिए एक नकली बनाने की आवश्यकता है, अन्यथा मुझे NullPointerException मिलेगा! मैं इसे EasyMock या PowerMock के साथ कैसे प्राप्त कर सकता हूं ??? @ टेस्ट सार्वजनिक शून्य टेस्टसमूह () {// सेटअप: बी बी = नया बी (); एक मॉकए = इज़ेक मॉक। क्यूट मॉक (एक्लास); b.setA_instance (mockA); // यदि आपके पास एक सेटर है / / सेटअप: उम्मीदों mockA.doSmth (); // व्यायाम EasyMock.replay (mockA); b.doSmthElse (); // सत्यापित करें EasyMock.verify (mockA); } @Test सार्वजनिक शून्य परीक्षणडोज़समयसेटसेटिंग () {// सेटअप: बी बी = नया बी (); एक मॉकए = इज़ेक मॉक। क्यूट मॉक (एक्लास); // एक स्प्रिंग प्रतिबिंब उपयोगिता प...

c++ - MPI Client fails at looking up Server port (MPI_ERR_NAME: invalid name argument) -

I am currently trying to connect to an MPI client with a server which publishes a certain name but this work And I do not have any clue about it. OpenMPi using MPI G ++ - 4.7, is 1.6 where / usr / lib64 / mpi / gcc / openmpi / etc / openmpi-default-hostfile below the "minimum" "(I do not like the questions using too many codes, but I think I should include it here): Problem shows: MY_IP / P> mpi_srv.cc #include & lt; Iostream & gt; # Include & lt; Mpi.h & gt; Int main (zero) {int rank (0); MPI_Init (0, NULL); MPI_Comm_size (MPI_COMM_WORLD, & amp; Rank); Std :: cout & lt; & Lt; "Rank:" & lt; & Lt; Rank & lt; & Lt; Std :: endl; Four POTN_M [MPI_MXFOXAPRAR]; MPI_Open_port (MPI_INFO_NULL, port_name); Four published_name [1024] = {'T', 'E', 'S', 'T', '_', 'P', 'O', 'R', 'T', '\ 0'}; MPI_Publish_name (publish_name, MPI_INFO_NU...

mongodb - From the SQL to the Mongo way of designing a DB -

I understand how to solve some issues on Mongo, I was working with SQL for some time and I know the basics of DB design, many of them are useless in Mongo because it is completely different. Here's an example I have user credentials (username, password), user information (name, last name, ...), and user decision information (friend list, choice, ecc). MySQL has a good way of organizing it, which is in 3 tables, one for credentials, one for general user information, and one for FB user information, all 3 related to User ID In this way, if I need to enter the user then I only need to query the credentials table, which has very little rows (3 columns; id, username, password) Okay, how can this logic be translated into non-relational realm? Can I expand my users by adding general information and Facebook notifications as an array?: User = & gt; Array ('username' = & gt; 'user1', 'password' = & gt; 'pass1', 'gInfo' => arr...

jquery - CKEditor set data, clicking on text area after clearing text set? -

I have a CKAditor and when I click on a drop down, this set populates the editor with the data function is. But when the user clicks on the area, he clears all the text. If a user first clicks on the field, then he writes a letter and then changes to the drop down to populate the editor, that's fine. @ Html.TextAreaFor (model = & gt; model. Message, new {id = "email-body", placeholder = "start typing your message ...", auto- Integer = "off" Ckeditor.instances ["email-body"]. SetData (msg.success) How to stop onclick special placeholder in ccditor but no help? It may work for you. CKEDITOR.instances [" Email-body "] .updateElement (); CKEDITOR.instances [" Email Body "] setData ('').

c# - I Cannot Access My Service From Remote Computer -

Please guide me to solve my problem. First of all, let me explain your program. I have created a service for balance check (i.e.) if you are input as an account number, the web service will return the account balance. Note: My client application has been developed in the Windows Store app. My webconfig file is as follows: & lt; System.serviceModel & gt; & Lt; Services & gt; & Lt; Service name = "account balance" & gt; And lieutenant; End Point Contract = "IQquatebillance" address = "AccountBillance" Binding = "Basic Httbidding" & gt; & Lt; / Endpoint & gt; & Lt; Endpoint Address = "Account Balance / MEX /" Binding = "MaxHTPBinding" Agreement = "IMDATDAXchange" & gt; & Lt; / Endpoint & gt; & Lt; Host & gt; & Lt; BaseAddresses & gt; & Lt; BaseAddress = "http://192.168.1.8:8081/AccountBalance.svc" /> Add & lt; / BaseA...

python - Biopython Iteration over FASTA doesnt work? -

Im a newbie in the field of programming and I am trying to understand the structure and logic behind the dragon loop. Will anybody please explain to me, why does not this work: Import the GCC from bio-import from CCIO i = 0 record = CQO.Red (open ("group %% d.fasta"). ,% I: Print GC (Record.sec) i + = 1 The above code generates the following error for the "FASTA" record: IOError: [Errno 2] is not a file or directory: 'group_% d.fasta') You have string formatting tho Ha is wrong. This: record = CQO.Red (open ("Group_% d. Fasta"), "Fasta")% i should be: record = CQO.Red (open ("group_% d.fasta"% I), "Fasta") I can move that thing with the statement in the statement to make sure that the file is actually closed correctly. Open ("group_% d.fasta")> Record = CQIO.Red (Fasta, "Fasta") with / html>

javascript - How to use AngularJS's scope values to generate custom html tag's attribute -

I'm trying to embed a Google Map's IFFR for my project, the problem of a per restaurant is that if The value of the address is in: $ scope.restaurant.address and I must include this code: & Lt; Iframe width = "450" ​​height = "250" src = "https://www.google.com/maps/embed/v1/place?key=MY_KEY&q= {{restaurant.address}}" & gt; ; & Lt; / Iframe & gt; {{Restaurant.address}} has not been properly interpreted, and when {a link is generated instead of the appropriate address} {{restaurant.address}} appears. Any clues? Any help would be appreciated, thanks in advance! Try something like this: applications. Controller 'SomeController', function ($ scope, $ sce) {$ scope.restaurant.address = '1313 Mockingbird Ln.'; $ Scope.url = $ sce.trustAsResourceUrl ("https: //Www.google.com/maps/ Embed / v1 / place? Key = MY_KEY & amp; q = "+ $ scope.restaurant.address);}); HTML: & lt; Ifr...

java - How to figure out what a .class file does? -

I would like to know how to reset the age of a hardware #macro ( renderBatteries $ batteryList) battery of #set ($ smartBatteryData = $ rack.getSmartBatteryData ()) #foreach (: in Tomcat files I extracts the function that age and found html renders $ batteries $) ... & lt; Td class = "formlabel" & gt; Age: & lt; / Td> & Lt; Td width = "50%" class = "formvalue" & gt; $! Battery.getBatteryAge () day (s) So I find it interesting to know where it is from info rack.getSmartBatteryData () ? If I am looking for grep for that ~ # grep -R 'getSmartBatteryData' / opt / * / opt / smu / tomcat / webapps / mgr / templates /app/screens/storage/racks/RackMacros.vm:#set ($ smartBatteryData = $ rack.getSmartBatteryData ()) binary file / opt / SMU / tomcat / webapps /mgr/WEB-INF/lib/SYMsdk.jar binary file matches /opt/smu/tomcat/webapps/mgr/WEB-INF/classes/com/bluearc/mgr/data/storageManagement/Rack.class binary file matches th...

jquery - javascript progressbar and slider -

I'm having some difficulty, I'm making my own control for an html5 video player. I have everything working correctly, but I would like to have a specific color and a different color of thumb left to the thumbs for my slider. I have seen another example here, which is almost done with jquery, but I can only work by clicking on it and not doing the project automatically with the video. I am new to javascript and can really do it with help to work. & lt; Script & gt; Var vid, playbtn, mutebtn, fullscreenbtn, finder, volumemider, curtitext, dirtimetext; Function Internal Player () {// Set Object Reference vid = document.getElementById ("my_player"); Playbtn = document.getElementById ("playpausebtn"); Mutebtn = document.getElementById ("mutebtn"); Fullscreenbtn = document.getElementById ("fullscreenbitten"); Seekslider = document.getElementById ("Finder"); Volumeslider = Document. GetElementById ("Volsm"); Cu...

android - How to fetch the rest of the JSON string from a pagination API? -

I have to get some code from the API and display the data in the ListView . I was able to get the JSON string from the API, but it is just a part of the data, and how do I get the rest of JSON ? Should it be handled on the client side? Should I use a different URL to get more data? Thank you in advance. You need to see the "link" header of the HTTP response. Example header in GitHub documentation Status: 200 OK / Link: X-rated limit-limit: 5000 X-rated limit: 49 99 Note the "link" which gives the URL for the next page Events are I have only done this in Python and not Android, so I do not know the exact details. I recommend that you, see, and document. Specifically, the method looks promising. If you are using, you should see.

java - Project created by libgdx is not working on android -

I use the latest version of the latest libgdx version (0.9.9) and adt (build: v22.6.2-1085508) I am with SDK toll version 22.6.2 and SDK platform-tools version 19.0.1 and SDK build version 19.0.3. My programs run fine on the desktop but when I want to emulate it on Android, I get an error (unfortunately, the Bird's Escape has been discontinued). My desktop is 64 bit and I have Arbyby and Armaby-V7A in the root directory of Android. Please see here: Settings for the device This is: 04-25 18: 14: 18.383: D / DelWiki (1198): Lib / is trying to load the data /app-lib/com.Solijon. BirdEscape.android-1 / libgdx.so 0xb3d03bb8 04-25 18: 14: 18.423: D / dalvikvm (1198): shared lib /data/app-lib/com.Solijon.BirdEscape pair went .android -1 / libgdx.so 0xb3d03bb8 04-25 18: 14: 18.423: D / dalvikvm (1198): not found JNI_OnLoad /data/app-lib/com.Solijon.BirdEscape.android-1/libgdx.so 0xb3d03bb8, 4/4/18: 14 : 18.503: D Excluding Android / TimeTime (1198): VM 04-25 18: 14: 18.503: W ...

jquery loading and setTimeout problems -

I am loading this page with .load () and timeout is 500, but when textera is focused, So I want the timeout to be changed to 5000000. This code is not working. Refresh the function () {var t = 500; $ ('#postholler'). Load ('postframe.php', function () {$ ("texture"). Focus (function () {var t = 5000000;}); setTimeout (refreshTable, t);}); } You can not change the timeout by changing the variable used to specify that The time was when the time was over. You have to stop the timeout and start a new one at that time: function loadPost () {$ ('# postHolder'). Load ('postframe.php', function () ($ ("Textarea"). Focusin (function () {explicit timeout (timer); timer = set timeout (refresh, 5000000);}); tim timer = set timeout (Refresh, 500);});}

python - Sequence Pattern recognition with Pybrain -

Image
I am constantly trying to use recurrent neural networks to classify a series of data. To be more specific, I have a sequence of sensor reading (which is continuous over time), I have to learn an algorithm which can detect the state related to this pattern, given the readings change. Example: Time step_1: 1.4 Time step_2: 1 Time step_3: 0.8 State = New Sequence: Time Phase 1: 0.4 Time Phase 2: 0.3 Time Phase 3: 0.1 State = Sitting I actually have 12 censors, I'm just showing a sequence of numbers for convenience. (Numbers are not real, I'm just trying to fulfill this idea)! I am trying to make my network with PyBrain RNN, however, I can not get a Data Set Container that can detect it, like information I tried to use sequential data But after some testing I came to know that this number is the next element in the sequence of numbers. Here's how I prepare my dataset: self.alldata = SequentialDataSet (ds.num_features, 1) # Now add samples to the dat...

forms - Jquery and a select menu, toggle just goes for a second then reverses -

यहाँ मेरे पास क्या है: $ (function () {$ ('# Race_info ') क्लिक करें (फ़ंक्शन () {var race = $ ("select")। Val (); $ (' # '+ race) .slideToggle ();});}); जब मैं इसे चलाने के लिए मेरी साइट पर रहते हैं यह div को दिखाने के लिए शुरू होता है, लेकिन फिर चयन कूदता वापस करने के लिए कूदता है और div फिर से छुपाता है Jsfiddle पर इसे लोड करने के लिए शुरू होता है यह एक पोस्ट अनुरोध के लिए पूछता है जो मैं पूरी तरह से के बारे में उलझन में हूँ लेकिन क्या आप मेरी सहायता कर सकते हैं, यह सिर्फ डिवेल दिखाएगा आपका लंगर टैग पृष्ठ को ताज़ा करने के कारण पैदा कर रहा है, डिफ़ॉल्ट ईवेंट रोकें:

ruby on rails - How to render circular images in WickedPDF? -

I am also using Twitter Bootstrap. There are images in my PDF, on which I have implemented the class: 'img-circle' . When I view PDF as HTML (the render PDF: "my PDF", show_as_html: true ) images are presented as circles. However, Why the image is not being displayed in the PDF version? version of QT that is of wkhtmltopdf Use was not used for a headless browser until recently: here wkhtmltopdf and QT projects: I'm not sure the latest wkhtmltopdf binaries is built against a new enough QT , but I am very new I will download and check it first: If it still is not, then become a new QT And a new wkhtmltopdf methods to compile binary:

Android drawable icon not appearing on 4.4.2 -

I have an Android app on the Play Store (Rally Nights) and it has just been brought to my attention that the Drawable Icon The overflow is not showing in the button, however the text is showing properly everything looks fine on 4.3 and I do not know what the difference might be when I debug using an emulator, this menu item Sets the icon and does not make any exceptions . I have tried to find out in hours that there is no benefit. Again, it works in older versions, but this icon does not display in 4.4.2 (KitKat). It crashes even on some 4.4.2 phones, although I can not get it to crash on the emulator. I have a target set 19.Miverson = 11; & lt; Use-SDK Android: minSdkVersion = "11" Android: targetSdkVersion = "19" /> I am also going to include the menu button which I have to see that it helps. & lt ;? Xml version = "1.0" encoding = "utf-8" & gt; & Lt; Menu xmlns: Android = "http://schemas.android.com/apk/re...

c - Is there any significant difference between `->` and `.` for accessing struct members? -

For people familiar with C and its nuances it can be very too , I do not I am familiar with either and can not tell that -> or . There is a important difference in reaching a member of a strat using . Like I have struct my_struct : struct my_struct {int x; Int y; }; Struct my_struct grid; Does this make a difference beyond the different syntax, do I via struct my_struct grid member of x Access the grid .x or grid-> x ? And if someone makes a difference, who can I like? Tried searching Google / SO, but I did not tell anything which was a favorite, if any, method. Both look correct, but I can not help but one of the more specific uses ( - & gt; ) is the case. It depends on how the structure is declared if we have the actual straight variable , Then use . If we have an indicator for a structure, then use -> : struct my_struct * s = ...; S- & gt; X = 5; Printf ("% d \ n", s-> x); Struct my_struct s2 = ...; S2.x = 4; Printf...

bash - Auto rename file when copy -

I copy a file to another location by cp C: /code.txt D: /code.txt I want to do , code (2) .txt or any other way to rename any other name, if it exists in the code.txt D directory Was there. Many thanks for any help! I got this answer cp --backup = numbered C: /code.txt D: /code.txt .

PHP/MySQL Using Variables and INSERT INTO syntax -

I am trying to pass variable values ​​in a MySQL database table. I am using a PDO to get access to the database, and I am able to resize the variable values ​​that I want to include in my browser. The only thing I can think of is that my syntax is wrong. I'm a newbie on using PHP / MySQL clearly. I have not found any errors in the information that is not going into my table values ​​('$ version', $ numeric, value, value, number, $ Pass_percent, $ earn_score, '$ username' '$ Email', '$ quiz_title', CURDATE ()) "; Create a MySQL table: Question ID INT not pure AutoConnect primary key, version text, INT points, passing passing times, received_core score, username text, email text, quiz text, date Default notation) default detector set UTF8 engine = InnoDB If your database is the connection object $ dbo , then it will generally like it. By calling the method prepared on your database connection object, A Create a statement: version...