Posts

Showing posts from January, 2012

Including another php file inside ajax call works but javascript file doesn't load -

I have a form wizard php page and in its related javascript (I'm an experimental prototype. JS BTW), I am updating a division with Ajax.Updater . What is really interesting is that the external php file is successfully included but the Javascript file is not. Here's my code: wizard.php & lt; Div id = "step1" class = "tab-panel active" & gt; & Lt; H3 square = "block" & gt; & Lt ;? = $ Core-> L ("report_selection")? & Gt; & Lt; / H3 & gt; & Lt; Div class = "control-group" & gt; & Lt; Label class = "control-label" & gt; & Lt ;? = $ Core-> L ("report_name")? & Gt; & Lt; Span class = "required" & gt; * & Lt; / Span & gt; & Lt; / Labels & gt; & Lt; Div class = "control" & gt; & Lt; Id = "report_selection" field = "report_selection" class = "m-wrap span10" ...

c# - CollectionChanged handler from ObservableCollection is null when getting item from Database -

We are currently working on a project and I am working on any kind of warning / information system. Original Thoughts: There are many questions, in each question there is an observation collection of answer items. All these items are saved in a SQL Server database (we are using the first method of unit framework code). Important parts of the question class: public class questions {public question () {... answer = new observation qualification & lt; Answer & gt; (); ...} public virtual supervision qualification & lt; Answer & gt; Answer {Get; Set; } ... extra stuff omitted} I want to add a collection handler to the compilation of the answer examples. I do this when I create a membership object for that question. This membership object is created and saved in my manager category which communicates with the reference of the database. Ways to do this: Public Zero CreateQuestion Subscriptions (Int UserID, Int qu ID, Notification Frequency Information Frequency...

android - MarkerManager Google Map Utility V2: intercept markerDrag events -

I am facing a problem with the marker manager: after adding elements to the cluster manager, I do not know The document related to pulling a marker in the intercept event is very little about this topic. Thank you for anyone who will help me.

VLOOKUP in 2 sheets of an excel -

I have a column in Excel of Excel that I want to compare with the column of sheet 2 of the same Excel. The value of the sheet 1 column to be present in some rows of Sheet 2 columns (not required by row by row). How to use VLUUP? something like this: = IF (ISNA (match 1, sheet 2! B: b, 0)), "no match", "match")

php - Redirect loop after login -

After login , I want to reach the same page. But I have a redirect loop of death security.yml Login: Pattern: ^ / admin / login security: false anonymous: true firewalls: dev: pattern: ^ / (_ (Profiler | wdt) | CSS | picture | js) / security: wrong protected_rea: pattern: ^ / admin form_login: check_path: _login_check login_path: _admin_login default_target_path: _admin_dashboard always_use_default_target_path: correct logout: path: _admin_logout target: _admin_login anonymous : ~ Access_control: - {path: ^ / admin / login, roles: IS_AUTHENTICATED_ANONYMOUSLY} - {path: ^ / admin, roles: [ROLE_USER, ROLE_ADMIN]} routing.yml: Pre> Dashboard Controller Php: * @ Root ("/" Admin / Dashboard ") * Extension Controller of / Dashboard Controller {/ ** * @ Root (" / ", Name = "_ admin_dashboard") * @template () * / public function index () (return array);}} and SecuredController.php: ... / ** * @ route ("/ admin") * / class...

regex - sible resular expression for multiple expression -

/ ^ मोज़िला। * एंड्रॉइड। * SonySGP311 / si /^Mozilla.*Android.* सोनी टेबलेट पी / सी /^Mozilla.*Android.*SGPT12/si /^Mozilla.*Android.*SGP311/si /^Mozilla.*Android.*Transformer/si /^Mozilla.*linux.*KFOT.*Silk/si / ^ मोज़िला। * लिनक्स। * केएफजेडब्ल्यूए। * सिल्क / सी मैं उपरोक्त नियमित अभिव्यक्ति को एक नियमित अभिव्यक्ति में कैसे डाल सकता हूँ ताकि यह उपरोक्त सभी रेगेक्स के साथ मेल खाता हो? इसे करना चाहिए: ^ (मोज़िला। * एंड्रॉइड * (सोनी एसजीपी 311 | सोनी टैबलेट पी | एसजीपीटी 12 | एसजीपी 311 ट्रांसफॉर्मर) | मोज़िला। * लिनक्स। * (केएफओटी। * सिल्क | केएफजेडब्ल्यूए। * सिल्क)) $ यहां डेमो: @बीबी के सुझाव पर अपडेट किया गया

Android Images in Email using Intent -

I have a webview that displays html content brought from the server, it works great. But if I try to use the intent to send this content to someone via email, the rest email is displayed correctly in the email client but in an box the image is not displayed instead of "obj". And when the same email is received, even then there are "obje" in the box for images Now I can open images by clicking on "obj" What is the image in the email? It is possible to display The images are part of html, not connected to the device. I have searched but there is no other solution to solve my problem. intent = new intent (Intent.ACTION_SEND); I.setType ("text / html"); I.putExtra (Intent.EXTRA_SUBJECT, this.news.getNewsTitle ()); I.putExtra (Intent.EXTRA_TEXT, Html.fromHtml (this.htmlContentDetails)); Try {startActivity (Intent.createChooser (i, "sending mail ...")); } Hold (android.content.ActivityNotFoundException e) {toast. Maketext (This...

php - The totals of the cart item amounts do not match order amounts -

I have read other posts on the same topic but I am sure that I am not eating issues on these posts. This really disappointed me so any help or advice would be appreciated. I SetExpressCheckout calls I'm making these arrays to be sent, but I get on each submission "does not match the amount of volume orders to train yoga", but I do not understand how I am! [METHOD] => SetExpressCheckout [USER] = & gt; Myusername [PWD] = & gt; 1398341028 [sign] = & gt; Xxxsignaturexxx [VERSION] = & gt; 85.0 [return values] => Http://www.mysite.dev/payment/process [CANCELURL] = & gt; Http://www.mysite.dev/payment/cancelled [PAYMENTREQUEST_0_PAYMENTACTION] = & gt; Sales [NOSHIPPING] = & gt; 0 [PAYMENTREQUEST_0_AMT] => 18 9.00 [PureRrayQVIS_0_IAMTT] => 18 9.00 [PAYMENTREQUEST_0_TAXAMT] => 0 [PAYMENTREQUEST_0_SHIPPINGAMT] => 0 [PAYMENTREQUEST_0_HANDLINGAMT] = & gt; 0 [PAYMENTREQUEST_0_SHIPDISCAMT] => 0 [PAYMENTREQUEST_0_INSURANCEAMT]...

wordpress - Commit to svn now error conflict while Git svn rebase -

I am quite new to this Github and Git I have two machines and in the end I was pulling from SVN (WordPress) And then managed to push the GIT branch to the SVN server. I use git for my plugin Now something went wrong in the middle, This was really stupid to release me through SVN. Now there are so many conflicts and I have also tried git mergetool with the git svn rebase command. In fact nothing is being solved At this time I do not want to delete my repository because already Forking / Monitoring In any way can I work GIT in the direction of STN WordPress? I just want to work on GIT repo and push the trunk to SVN when I'm ready. I'm still embarrassed for the mistake. But this was a serious error because the plugin was the last committed SVN Thank you, in fact, would appreciate your help, if possible, do not remove existing GIT repo

c# - How to format enum with flags attribute as hex value? -

मैं enums toString विधि का उपयोग करके enum मान प्रदर्शित करने का प्रयास करता हूं। Enum में फ्लैग विशेषता है। ऐसे मान हैं जो enum मानों के किसी भी संयोजन से मेल नहीं खाते हैं। इस मामले में, ToString संख्या दशमलव के रूप में देता है, लेकिन मैं उसे हेक्स स्ट्रिंग के रूप में प्रदर्शित करना चाहता हूं। का उपयोग करना टूस्ट्रिंग ("X8") हमेशा हेक्स मूल्य वापस कर देगा। मैंने कोशिश की Enum.IsDefined , लेकिन यह गैर-संयुक्त मान पर केवल सच देता है। उदाहरण: 0x00000201 - & gt; "XXt, TSW_AUTO_DETECT" (ज्ञात मान) 0x00010108 - & gt; "00010108" (अज्ञात मान) Q: कैसे "toString" अज्ञात enum मानों के रूप में हेक्स वैल्यू? आप जांच सकते हैं कि मान के पास कोई अन्य बिट्स की कुल बिट मुखौटा झंडे की गणना यदि हां, तो नंबर लौटाएं, अन्यथा सामान्य टॉथरिंग: सार्वजनिक स्थिर स्ट्रिंग GetDescription (EnumName मान) {var enumtotal = Enum.GetValues ​​(typeof (EnumName))। कास्ट & lt; int & gt; () .ग्रेगेट ((i1, i2) = & gt; i1 ...

javascript - html collapsed/expanded tree -

I am using code to generate a tree in html, and the problem is, every time I use the tree Refresh the page to detail. I want to make it so that when I open the page, some branches will expand and some will be stacked, it depends on that specialty. For example: & lt; Span & gt; & Lt; I class = "icon-plus-mark" & gt; & Lt; / I & gt; Parents 1 & lt; / Span & gt; & Lt; Ul & gt; Children go here & lt; / Ul & gt; & Lt; Span & gt; & Lt; I class = "sign-zero-sign" & gt; & Lt; / I & gt; Parents 2 & lt; / Span & gt; & Lt; Ul & gt; Children go here & lt; / Ul & gt; When I open the page, I want to see the parents of 2 children, but not the parents. I'm a newbie in HTML and am completely new to CSS and Javascript. Therefore any suggestion will help. You can add the beginning of the closed code of each element mark as your icon square use Taxes collapsed Code...

javascript - jQuery: $.get(url) breaks my sequential script execution -

Image
My attention is to check a calculated image URI, if it exists ... If I This image, shown as an overlay: $ (First_upplies). (Function () {$ ('# any_DOM_id'). Attachment ('& lt; img id = "first_image" (* & lt; img id = "first_image" src = "' + fallback_url + '" src = "' + First_url + '"/>);}) failed (function () {$ (' # any_DOM_id '). / & Gt;');}); / *** Here something is going big and is calculated *** /. . . . . AdInd ('& lt; img id = "second_image" src = "' + second_url + '" / "gt;';)}} failed (function () ($ ('# any_DOM_id'). Attachment ('& lt; Img id = "second_image" src = "'+ fallback_url +'" / "gt; ');});); & amp; id =' (img id =" third_image "src =" '+ third_url + "" Attachment ('& lt; img id = "third_image" src = "' +...

php - Including External stylesheet in CodeIgniter -

This is Hardic vyas, new to CodeIgniter, I know basic about CodeIgniter, I want to include the template in CodeIgniter: But first of all, I need to include an external stylesheet in one page, but I can not, I have to face a 403 error. Here is my code: Administrators header.php ('Title') view; }}? & Gt; View header.php & lt; Html & gt; & Lt; Top & gt; & Lt; Title & gt; Demo & lt; / Title & gt; & Lt; Link rel = "stylesheet" type = "text / css" href = "/ application / views / mystyle.css" /> & Lt; / Head & gt; & Lt; Body style = "background-color: antiquewhite" & gt; & Lt; H3 style = "background color: # 990000; color: #ffffff" & gt; Hello & lt; / H3 & gt; & Lt; / Body & gt; & Lt; / Html & gt; CSS mystyle.css .red {background-color: red; } Please provide any easy way to do this and also tell me how to in...

java - Launch browsable intent in correct app -

My problem is: There is an activity in my app that has been declared in the manifest : & lt; Category android: name = "android.intent.category.BROWSABLE" /> When I click on the link received by SMS, I am using it to launch my app. The problem is that the app is running in the context of the message and when I press the back button, it launches the app in the default context. What do I want, when I click on the link, this app opens in my context how can I fix it? Managed to work on it on the manifest: Android: launchMode = "Autotusk"

getline(cin) behaving unexpectedly (c++) -

मेरे पास निम्न फ़ंक्शन हैं: शून्य खिलाड़ियों (स्ट्रिंग और नाम) {char सत्यापित करें; Cout & lt; & lt; "खिलाड़ी नाम दर्ज करें:"; getline (CIN, नाम); Cout & lt; & lt; endl & lt; & lt; "आपका नाम है:" + name + ", क्या यह सही है? (हाँ के लिए वाई, कोई अन्य कुंजी नहीं):"; CIN & gt; & gt; को सत्यापित; अगर ((सत्यापित करें == 'वाई') || (सत्यापित करें == 'वाई')) {सत्यापित == 'एन'; } अन्य {playersetup (नाम); }} यह खिलाड़ी के नाम के लिए पूछता है, उपयोगकर्ता को अपने नाम को सत्यापित करने के लिए कहता है, यदि वह खुद को शुरू करने के लिए कॉल नहीं करता है। हालांकि, यह ऐसा उत्पाद है जो दिखता है: प्लेयर नाम दर्ज करें: उपयोगकर्ता प्रवेश करता है: जॉन स्मिथ आपका नाम है: जॉन स्मिथ, क्या यह सही है? (हाँ के लिए वाई, किसी भी अन्य कुंजी को नहीं): उपयोगकर्ता में प्रवेश करता है: n प्लेयर नाम दर्ज करें: (उपयोगकर्ता इनपुट का मौका नहीं दिया जाता है कुछ भी) आपका नाम है:, क्या यह सही है? (हाँ के लिए, हाँ के लिए कोई...

jQuery .append doesn't work -

I want to insert something in my form, which is plugged in hard and hard and I do not mess with it Wanted plugin files, so please give me the .append & lt; Script & gt; JQuery ('# edit-profile') is found. ('& Lt; p & gt; smth & lt; / p & gt;'); & Lt; / Script & gt; I have written something like this and as far as I can see it should work. The console in Chrome does not show me any bugs. Is there anything wrong here? I am using the most modern jQuery and because of the security of WordPress, I am using jQuery instead of $. Wrap it into domain preparation. Because # edit-profile should be at the time the script is executed, jQuery (document) .ready (function () {jQuery ('# edit-profile') .app ('

How to refresh an Excel table filled with data from a MYSQL Database -

That's why I want to refresh my Excel table from an MYSQL database every time that every row gets often I am able to import the database into my Excel table, but then I can not understand a data added to the MySQL database to update that table. To be able to connect to my MYSQL database, I use mysql software for excel - version 1.2.1 any The person has an idea that if there is anything that can be done? Instead of importing your data, link your data (using data connection).

java - enters an infinite loop when catching exception -

पूर्णांक विकल्प; जबकि (सच) {try {option = sc.nextInt (); } पकड़ (अपवाद ई) {System.out.println (e); जारी रहना; } यदि (विकल्प! = 1 & amp; amp; विकल्प! = 2) {System.out.println ("कृपया ऊपर दिए विकल्पों में से कोई एक चुनें!"); जारी रहना; } टूटना; } तो क्यों मैं एक स्ट्रिंग इनपुट एक अनंत लूप में प्रवेश करती है? क्योंकि आप अगले उपयोगकर्ता इनपुट को फिर से स्कैन करने के लिए लूप के बीच में नहीं रोकते हैं।

knockout.js - How do I keep child div from being bound by Knockout JS using foreach and SignalR -

मैंने निम्नलिखित ब्लॉग पोस्ट का उपयोग करके एक फेसबुक शैली टिप्पणी प्रणाली बनाई है: मैंने कार्यक्षमता बढ़ा दी है छिपी हुई सीएसएस वर्ग के नाम को जोड़ने / हटाने से टिप्पणी डिज़ाइन को टॉगल करने का एक तरीका जोड़ना अगर मेरे पास ब्राउज़र खोलने का केवल एक उदाहरण है तो यह अच्छी तरह से काम करता है हालांकि, जब मैं एक दूसरा ब्राउज़र खोलता हूं, तो उस ब्राउज़र को लोड करने से दोनों ब्राउज़र उदाहरणों को उनके डिफ़ॉल्ट "छिपा हुआ" वर्ग में टिप्पणी अनुभाग रीसेट करता है। क्या किसी का सुझाव है कि टिप्पणी सेक्शन डिवेल को नॉकआउट बाइनिंग से कैसे बांटना है ताकि वह डिवा क्लाइंट पक्ष को नियंत्रित कर सके और नॉकआउट के माध्यम से? यह मेरा संक्षिप्त कोड है जिस पर ऊपर वर्णित ब्लॉग पोस्ट पर आधारित है: HTML: ... & lt; ul id = "msgHolder" class = "post-ul" data-bind = "foreach: पदों '& gt; & Lt; li वर्ग = "पोस्टहोल्डर पोस्ट ली" & gt; & Lt; div class = "postfooter" & gt; ... & lt; a class = "togglecommentSection" href ...

Get all QC tests from test plan through OTAClient - JAVA -

What is the interface to use for all test cases in the QC test plan? We have an ITSAT factory for test set details in test lab. But how can we get all the test details from QC in some collection item in the value-added pair? Data retrieval is more important for now. The use of OTAClient.dll has been converted into java jar and using Com 4J as a bridge! Thank you in advance! ITreeManager and ITestFolder / ITestFolderFactory are interfaces, for testing ITestFactory interface. With the NewList methods of TestFolder and TestFactory objects, you can create a recurring function that tests you in all test plans.

Php: how to make variables work in mysql instructions -

I am trying to create one last online system and this is the code that must be run after login $ name = $ user ['username'] mysql_query ("utidad user set last_action = now () WHERE username = $ name"); $ Message = "connected"; In general, if I type this code in the php tag the name is displayed resonance $ user ['username'] but it seems that this variable does not work in mysql_query Why? How should I set "$ name" to do this work? You will need to type '$ name' . Try: mysql_query ("UPDATE user SET last_activity = now (WHERE user name = '$ name'");

c++ - Catch shutdown console in Linux -

I want to capture a user shutdown in the Linux terminal, such as: sudo shutdown I am using the following C ++ code: myAct.sa_handler = myStructure :: mySignalHandler; Signigation (my signal, and act, null); And I'm using a script to send a mySignal signal. However, using a script means to modify the system's main files, and I do not want it. Is there another way to capture shutdown signals in Linux through the C ++ code? According to the man page, when the shutdown is run, all processes send a cigarette. So if you write your signal handler for SIGTERM, then you do not need to include any other script.

c - Replacing the close() function in Linux with my own close() function -

मैं लिनक्स में close () फ़ंक्शन का अपना स्वयं का कार्यान्वयन करने का प्रयास कर रहा हूं। क्यूं कर? क्योंकि मुझे अभी पता चला है कि आप ऐसा कर सकते हैं और यह मजेदार लग रहा है। यहां myclose.c है: #include & lt; stdio.h & gt; इंट क्लोज़ (इंट एफडी) {printf ("क्लोजिंग एफडी:% डी \ n", एफडी); वापसी 0; } यहां मेरा मेकफाइल है: सब: myclose.so my-close.so% .so:% .o जीसीसी -शेअर -ओ $ @ $ & LT; % .o:%। C gcc -c -fPIC -o $ @ $ & lt; संकलन के बाद, मैं चला: निर्यात LD_PRELOAD = `pwd` / myclose.so कोड> फिर मैं चलाता हूं: cat myclose.c मुझे मिल रहा आउटपुट है: #include & lt; stdio.h & gt; इंट क्लोज़ (इंट एफडी) {printf ("क्लोजिंग एफडी:% डी \ n", एफडी); वापसी 0; } समापन fd: 3 यै! सही काम करता है? लगभग। cat कॉल बंद () एक से अधिक बार, लेकिन हम केवल आउटपुट की एक पंक्ति देखते हैं। strace (और सामान्य ज्ञान) के अनुसार, close () को फ़ाइल डिसिप्टर 1 और 2 के लिए भी बुलाया जाना चाहिए यदि मैं cat * को चलाता हूं और निर्देशिका में...

android - MVVMCross: Binding Two Way doesn't update viewmodel -

I'm trying to tie a property into a custom control in a Xamarin.Android project. Public category MyControl: Relative layout {public supervision collection & lt; String & gt; MyProperty {Get; Set; }} When MyProperty is updated to the ViewModel side, it updates exactly in the MyProperty view. However, if I update Myopporte to the scene, then I can not do anything. Binding: Public class MyControlMyPropertyTargetBinding: MvxAndroidTargetBinding {Private bool _subscribed; MyControl Protect MyControl ({Return (MyControl);}} Public MyControlMyPropertyTargetBinding (MyControl Target): Base (Target) {} Safe Override Zero SetValueImpl (Object Target, Object Value) {var myControl = (MyControl) Target; MyControl MyProperty = (Observable Collection & lt; String & gt;) Value;} Public Override Type Type {Receive {Return Type (Observeable Collection & lt; String & gt;);}} Public Override MvxBindingMode DefaultMode {get {return MvxBindingMode .TwoWay;}} Publ...

python - Not Getting the object in template Django -

मुझे त्रुटि मिल रही है कि json सीरियलजबल नहीं है। views.py crave.html फ़ंक्शन अगला () {चेतावनी} ("आप में") $ .एजेक्स ({url: "/ crave / get_post /", टाइप करें: "GET", डेटा: "", सफलता: फ़ंक्शन (प्रतिक्रिया) {अलर्ट ('सफलता'); चेतावनी (प्रतिक्रिया Craves) //$ ('.ajax प्रगति' ).html (प्रतिक्रिया। HTML_USER); $ (' .ajaxProgress ') एचटीएमएल (response.craves)। }, त्रुटि: फ़ंक्शन () {चेतावनी ('कुछ त्रुटि'); }}); } मुझे typeError प्राप्त हो रहा है: [& lt; CraveData: गौरव & gt ;, & lt; CraveData: Rahul & gt;] JSON सीरियल योग्य नहीं है लेकिन जब मैं craves = len (craveData.objects.filter (person = request.user) प्राप्त करने की कोशिश की) मुझे मूल्य मिल रहा है कृपया टेम्पलेट्स में ऑब्जेक्ट प्राप्त करने में मेरी सहायता करें। एक उचित उपयोग करें: django.core से आयात serializers def get_post (अनुरोध): अगर request.is_ajax (): यदि request.method == "GET": craves = CraveData.o...

internet explorer - HTML email not rendering correctly when Outlook user views in IE browser -

I created a responsive email using conditional statements for Outlook (it is not responsive in Outlook) It looks fine in the clients, but when an Outlook user chooses to view an email in a browser (Outlook Auto opens IE, I have IE10), it seems that 50000% has zoomed in like I have sensitive at all times Email and so on This problem has never experienced. The only difference is that most of the material is dynamically pulled from DB. Does anyone have any idea why this is happening? If this helps, then the functionality and head code from the email are given here: & Lt; Meta name = "viewport" content = "initial-scale = 1.0; maximum-scale = 1.0; user-scalable = 0" /> & Lt; Title & gt; Untitled & lt; / Title & gt; & Lt ;! - [gte mso 9] & gt; & Lt; Style type = "text / css" & gt; .noOutlook {display: none; } #outlook {display: block;} & lt; / Style & gt; & Lt; [Endif] - & gt; & Lt; / Head & gt;...

mysql - Grouping from highest to lowest -

मेरे पास इस तरह एक तालिका है: + -------- - + -------------- + --------- + | विस्मयकारी | विशेषता | डॉक्टर | + --------- + -------------- + --------- + | 1 | ऑन्कोलॉजी | 3611 | | 1 | न्यूरोलॉजी | 1 9 31 | | 1 | रुमेटोलॉजी | 1471 | | 0 | ऑन्कोलॉजी | 35 | | 0 | रुमेटोलॉजी | 28 | | 0 | न्यूरोलॉजी | 20 | + --------- + -------------- + --------- + उपरोक्त तालिका क्षेत्र डॉक्टर अब, मैं निम्नलिखित परिणाम प्राप्त करने का प्रयास कर रहा हूँ: + ------ --- + -------------- + --------- + | विस्मयकारी | विशेषता | डॉक्टर | + --------- + -------------- + --------- + | 1 | ऑन्कोलॉजी | 3611 | | 0 | ऑन्कोलॉजी | 35 | | 1 | न्यूरोलॉजी | 1 9 31 | | 0 | न्यूरोलॉजी | 20 | | 1 | रुमेटोलॉजी | 1471 | | 0 | रुमेटोलॉजी | 28 | + --------- + -------------- + --------- + क्या कोई है यह करने के लिए जिस तरह से आदिल मीएडल के जवाब में ... इन क्वेरी में उपयोग मापदंड थे: (पुनश्च: मुझे लगता है कि यह एक छोटे संदर्भित तालिकाओं के बिना underestand को भ्रमित कर सकते हैं) का चयन करें su.visitty, cs.speci...

java - Using streams to decrypt and unzip to limit memory usage? -

I have a very large zip file, 2.5 GB, which is encrypted. I can not decrypt the whole file in memory And do not want to open them there for production. So I'm trying to use the currents to limit the amount of memory used. I have tilted the following to do this (error handling and stream ending has been left for clarity): SECRETARY SPECEC keySPEC = new secret of SPEC (mike) "AES"); Cipher cipher = cipher Get Instances ("AES / CBC / PKCS5 Padding"); FileInputStream fis = New FileInputStream (new file (pathToEncryptedFile)); Cipherinputstream cis = new cipher inputstream (fis, cipher); ZipInputStream zis = new ZIPInproststream (new BufferedInputStream (cis)); Zipantries = null; While ((ze = zis.getNextEntry ()) = null) {string filename = ze.getName (); System.out.println ("Enter the zip entry:" + file name); } This works for approximately 50% of my files, even though they are all zipped and encrypted in the same way. Exception will be found in...

stored procedures - How do I change the format of my date in SQL Server -

I am using SQL Server 2008 R2 and I have a table that has the start date in my table, Looks like, 1977-10-17 00: 00: 00.000 How do I change those values ​​to represent 10-17-1977? Apart from this, if date is 19 00-01-01 00: 00: 00.000 then I want to convert it to zero value. Are there any commands or stored procedures for these types of changes? Thanks Nick You probably use later to get your format Like: Convert from MyTable (varchar (10), MyColumn, 110); Here we are converting your data into a character value, but with a special date style (style 110). Your tap issue can be sorted by switch or with the function: Select nullif (MyColumn, '19010101') from MyTable; Select case when MyColumn = '19010101' then tap MyTable and end MyColumn; Note that I'm assuming MyColumn is stored in the form of a day-time or similar datatype if not, then you cast They can do according to the above documents. Feel free to combine tasks like: select ...

ios - Transfer files between Mac/Windows and Iphone App -

I am working on the iPhone app and transferring files between Mac / Window and Mary (PDF, Image, Test) Wish me iPhone app, I have to give a good suggestion to do "best way": I knew there are some things called bunge in Mac, but I want to share files between my iPhone Mac / Windows and my app. App to exchange Any suggestions would be appreciated and thank you in advance! Airflow, launched in iOS 7, is a great Bluetooth transfer library.

Generate ports in VHDL? -

Is there a way to generate port announcements in VHDL? I would like to do something similar to #IFDEF for debug signals for pins for an oscope, in this way I can enable or disable debug logic immediately. For example: is the unit my_entity port (debug_label: if debug_on generates 1 debug 1: out; and debug_label; ....); End component; When I try to do something like that, it does not work. Is there any way to do this work? Or is there an alternative way of doing something? The port may not be conditional, but for example std_logic_vector via normal mode Can be configurable from, and length can also be 0, which results in zero range. It is showing that there is a unit: unit MDL is normal (DEBUG_LEN: natural: = 0); Port (... debug_o: out std_logic_vector (DEBUG_LEN - 1 below from 0)); End unit; You should run a select synthesis how your selected synthesis tool handles the null range while specifying the body.

java - Is inter-class dependency an anti-pattern -

Best explained my small snippet - here we have two classes here Math and SolveEquation . They both rely on one another, is this traditional practice? Or is there an anti-pattern that should be avoided from all expenses? Note: Please avoid alternative solutions. This example was made to answer the suspicions made by me. Thank you. Example: Request for class solution {public static insulequuction (int x, int y) {return Math.add (x, y) + Math.sub (X , Y); }} Class mathematics {public static int activation (Intex X, int y) {return SolveEquation.solveEquation (x, y); } Adding public static (int x, int y) {return x + y; } Public fixed int sub (int x, int y) {return x - y; }} This condition is called a circular dependency, and yes, should avoid. At least if you know that you can avoid them, then do so. Edit: There are several reasons why you should not stay with them. The first is that some languages ​​(if I remember that have already happened to me in C #), then you ...

android - Parsing Wordpress JSON api -

I am trying to parse the WordPress Jason API on my Android application, but I do not have a thumbnail URL here before The result should be a string, so the result should be: http: \ / \ / www.androidaci.net \ / wp-content / uploads / / galaxy_r_i_i_i_i_i_i_i_i_station_test_test-150x150.jpg Thank you for your help!

angularjs - Why is Angular JSON coming in as a ListBuffer? (And how to parse...) -

edit I initially mis-described it - it was written again below. For some reason, I can not get the angular to send the Jesonon payload in such a way that it is considered as a simple string. Looking at the body, it is always ListBuffer for any unknown reason. Code Application.scala (Reading is taking [string] and (JSP script \ "language") [int]) ((name ): String, language ID: int) = & gt; User (None, Name, Language Ind)) Submit SubmitUser = Action (BodyPursers.prsegenson) {Insert Request = & gt; Val userResult = request.body.validate [user] userResult.fold (Errors => (BadRequest (Json.obj ("Status" -> "KO", "message" - & gt; J.S.R.R. Tupet Jason ( Errors)))}, user = & gt; {userDao.add (user) is ok (Json.obj ("condition" -> "OK", "message" -> ("user" "+ user .full_name + "'saved'.);)}}} User.scala case class user (id: option [int] Full_name:...

jquery - How to detect window resize and then change the javascript file being added to the header? -

To find out the size of the screen I have this jQuery and then attach a file to the header based on sceen size Please. var scriptSrc = ''; Var widow with = $ (window). With (); If (widowWidth> = 1024) scriptSrc = '/js/desktop.js'; If ((Widow Quarter I have $ (window) with it Have tried to use Resetize (), but I am unable to extract the file that was originally added before resizing. I have you to change my code and as you can see it will add a JS file based on the size of the screen, but I would also like to change the screen but would like to change it. Thank you for your time! What do I use here: $ (window) Tie ('resize', function (event) {// which you want to run here}}; Just set a variable for the width and height of the window and check That's what they are inside this function. When the screen resizes then with reloading the whole page to replace its javascript file ... I do not think it is possible. A job It may run all t...

python - Import variables without displaying source code -

I am using Python 2.7 with Spider I have a file (xxx.py) The value of some variables using an order like this: xxx Import v1, v2, v3, v4 to I can use the variable, but Spider shows me all output from xxx.py before the output of the current program (runs a series of print commands in the xxx.py file). Is there something that I can do to present only the output from the current file, running the code form xxx.py in "background"? If there is a code that you do not want to execute while modulating the module, then preserve it Should go: if __name__ == "__main__": # to execute the code only when the module is executed # as script, not imported. The modules to be imported should not be written on the standard output.

How to insert xml node in Sql Server without inserting empty namespace? -

यह एक उदाहरण है कि मेरा स्रोत XML कैसे दिखता है & lt; catalog xmlns = " http://schemas.example.com/stuff/stuff"> & Lt; स्ट्रिंग कुंजी = "नाम" टैग = "22 ए 41320-बीबी66 -41 ए 9-8806-760 डी 1 3679 सी 6 सी" & gt; दस्तावेज़ शीर्षक 1 & lt; / स्ट्रिंग & gt; & Lt; स्ट्रिंग कुंजी = "नाम" टैग = "023463cf-9237-45b6-ac3f-621b9b09f609" & gt; दस्तावेज़ 2 का शीर्षक & lt; / स्ट्रिंग & gt; & Lt; / सूची & gt; मैं स्ट्रिंग नोड्स के माध्यम से लूप की योजना बना रहा हूं और उन्हें नोडल नोड्स में बदलना है (यह केवल लूप का पहला चलना दिखाता है)। हालांकि, जब मैं नया नोड सम्मिलित करता हूँ, यह एक खाली नाम स्थान को सम्मिलित करता है I यह मेरा परिणाम है: & lt; कैटलॉग xmlns = "http://schemas.example.com/stuff/stuff" & gt; & Lt; स्ट्रिंग कुंजी = "नाम" टैग = "023463cf-9237-45b6-ac3f-621b9b09f609" & gt; दस्तावेज़ 2 का शीर्षक & lt; / स्ट्रिंग & gt; & Lt; दस्त...

ios - Positioning of elements inside CCNode -

Image
I have created a CCNode in SpriteBuilder and add some children nodes (label, button and sprite) to add it. On the SpriteBuilder I made time to run consistently in the points regarding the position of the children node parents in the upper left corner. I change the size of the parent's node content, but the position of children remains constant, in relation to the top. I do this to extend the node: self .contentSize = CGS immec (self cross system size. Width, set content size. + 50 + high); I give color node (node ​​that is dark blue which is a child of node being expanded and this height of is 100%) before and after the expansion It checks the contentize and actually increases 50 points but on the screenshot we can see that the dark blue area does not increase. I also check the status of the title label before and after the extension and in this case the number is equal in the top left corner, however in the screenshots we can see that it is far from the top. ...

html - jQuery hover function, not working as expected with paragraph tags -

I have paragraph tags inside a hover div and every time The mouse enters the animation in a new paragraph. Any ideas on what is wrong? js $ (document) .ready (function () {$ ($ ('# Col1start'). $ ('# Col1start'). $ (' Stop (True, True) .Fadeine (800);}); $ ("# Container 1A"); Stop (True, True) .FadeOut (800); $ ('# col1start'). Stop (true (true, true). Fadeaut (800); $ ('# col1hover') Hide (); $ ('# col1start'). (True, true). FadeIn (800);});}); HTML & lt; Div id = "container1a" & gt; & Lt; Div id = "col1start" & gt; & Lt; P & gt; Text 1 & lt; / P & gt; & Lt; P & gt; Text 2 & lt; / P & gt; & Lt; P & gt; Text 3 & gt; & Lt; / P & gt; & Lt; / Div & gt; & Lt; / Div & gt; You can have functions that handle both events at once, this code You have a good start. $ (document) .ready (function () {$ ('# cont...

Returns values of functions Python Multiprocessing.Process -

I am trying to generate a checksum of two identical files (in two separate directories) and using multiprocessing I am here. Process () However, when I multiprocessing on a function generating checksum When I run the process () object, I get this return value: & lt; Process (process-1, off) & gt; & Lt; Process (process-2, off) & gt; This checksum should be a string of strings. Does. I am being processed through multiprocessing which how to get the return value of the function. Process () object? Thank you. This is relatively good on this topic; Pipes You can communicate through a pipe in the process object; From the docs: with multiprocessing import process, pipe def (conn): conn.send ([42, none, 'hello']) conn.close () If __name__ == '__main__': parent_conn, child_conn = pipe () p = the process (target = f, args = (child_conn,)) p.start () print parent_conn.recv () # print "[42, someone Also, hello ...

ruby - Parse many numbers containing commas from string -

Text after "div class =" itemprop = "text"> I have a series of wires that include all the following 1 or many numbers (in this case a number will be 123123123) format "Some other numbers are 123,345,123" This is a number 123,124,123 ", 231,123,123, 124,152,123" "; 123,123,123; This is a strange situation 123,124,125 More text" Is there a clear way to parse these numbers in an array or a string that I can split that looks like this? Finally, I was able to separate the numbers in such a way: Want to be 123456 > "string" .scan (/ \ d /) But obviously it is only giving me a comma without number and it is also not very different from the other. itemprop = "text"> do this way string.scan (/ [\ d ,] + /)

c - Accessing device memory in Cuda -

I'm trying to access device storage after copying the device memory to the host memory. And when you try to print the data copied from data storage to device memory, the performance result is inappropriate. It says the fault of partition where I found out that I am trying to print data from memory which is available Is not or is not able to use. How to access this device's storage and I want to make sure that if I modify the host memory data then I want this change to be seen in the device memory data, when I print it. Here my code is below is included in //, the system #include & lt; Stdio.h & gt; # Include & lt; Assert.h & gt; // Simple utility function to check CUDA runtime errors; Zero check CUDAError (const char * msg); Int main (int argc, char ** argv) {// pointer and host memory int n, dimension for dimA; Float * h_a; // pointers for device memory float * d_a, * d_b; // allocate and start host memory / ** bonus: Try using cudaMallocHost instead...

python - OS X Scapy Promiscuous Mode -

I am using scripts for a list of all HTTP host headers sent to my network. Currently the code is: #! / Usr / bin / env python import sys.path.append ("/ usr / local / lib / python2.7 / site-packages") Re-import from Scapy.all import * Import OS import urlib conf.sniff_promisc = True HOST_REGEX = "(? & Lt; = \ r \ n Host \ :) ([A-Za-z.]) {4,40} (? = \ R \ n)" def print_host_header (pckt): If pckt: Raw = pckt.getlayer (raw) if raw: raw_pckt_data = raw.load host_results = re.search (HOST_REGEX, raw_pckt_data) if host_results: print "[*] Request:" + str (host_results.group (0)) if __name__ = = "__main__": if os.getuid ()! = 0: Print "[!] Is not running as root." It works very well (obviously it can not read encrypted traffic with SASL / TLS) (Remove) (1) SPIF (filter = 'TCP', PRN = print_host_header, store = 0) ), but I do not want to capture any packet from my laptop (which is the computer Script is running) I correct ...

java - Best practices for indicating a field has been modified in GWT -

There are several key objects in my application, whose fields are accessed by several presenters. At present, my use of gates / sets is limited to cases where verification is necessary. I want to track whether field values ​​have been updated (and therefore database updates are required). To do this, I am considering to include the boolean flag, the third (to indicate that the existing value is recovered or separated from the default) and deleted (to indicate that an object Reports related to should be removed). By adding such flags to orbit in the classroom, either (A) using the setters, and setting the flag values ​​in the setter when the fields are updated) or (b) the selectors should be selected, but any code is required which field Sets flags to modify the value (clearly prone error). Is there a great way to keep track of field meta-data? If the object is stored as session attribute, then you session Regarding the state of the state (added / deleted / replaced) in the fi...

ios - UIImagePickerController not rotating and Translating/Scaling -

I am trying to reverse my UIImagePickerController so that it is capable of filling the screen of both the iPhone 5 and obviously, Inverted. I have a code for UIImagePickerController: - (zero) ApplicationDidbackActive {UIImagePickerController * imageViewPickerController = [[UIImagePickerController alloc] init]; ImageViewPickerController.sourceType = UIImagePickerControllerSourceTypeCamera; ImageViewPickerController.showsCameraControls = No; ImageViewPickerController.cameraViewTransform = CGF TransformMarketation (DGEREERIIDENS (180)); ImageViewPickerController.cameraViewTransform = CGFint TransformMacronslation (0.0, 71.0); ImageViewPickerController.cameraViewTransform = Cigphin TransformsKeyle (Image ViewerControllerCamera Transformation Transform, 1.333333, 1.333333); [Self present ViewController: animated imageViewPickerController: not completed: NULL]; } If I run this code, I do not get any inversion. If I modify it like this: - (zero) ApplicationDidbackActive {UIImageP...

objective c - Why drag UILabels only to the .m file from storyboard? -

In which case should I create an asset in .m file? In the past I saw that every person made them in .h files. Will it be private or why should I use this solution? @interface StatViewController () @property (weak, non-meticulous) IBOutlet UILabel * sampleText; @end you leave an asset in .m file for In the scenario you are showing that you will leave sampleText property in the header file if you should be able to reach out of your classroom otherwise you can class it to continuity .

how to keep form element inline with text on headline in HTML/css/boostrap 3? -

Image
I am using bootstrap3 in my HTML / CSS template; Here's what my page looks like: I want Star Star (Which is next to the text). There is a button button, submitted on click of the form. So far my HTML code is available to get: & lt; Div class = "col-6 col-sm-6 col-lg-4" & gt; & Lt; H3 & gt; 2004 Toyota Prius $ 7000 & lt; Form Action = "/ Post / Unblockmark" method = "Post" & gt; & Lt; Input type = 'hidden' name = 'csrfmiddlet' = 'ME7CDsBM2mPw2uWSyV28rgQMbE5bEDG2' / & gt; & Lt; Input type = "hidden" name = "bookmark_id" value = "1839" /> & Lt; Button type = "submit" class = "bookmark" id = "1839" & gt; & Lt; Span class = "glyphicon glyphicon-star" & gt; & Lt; / Span & gt; & Lt; / Button & gt; & Lt; / Form & gt; & Lt; / H3 & gt; & Lt; P & gt; & Lt; Small ...

image - How to use img ng-src in AngularJS on android phone? -

Most relevant Q & amp; I have got and I have read. I am trying to use it in my app and I saw that the demo uses the full URL for the slide like this: image: 'http: //placekitten.com/ '+ NewWidth +' / 300 ' . This works on my localhost (Mac), but I do not think the images (slides) are on my Android Google Nexus phone because I only use such image paths like this: Code> image: '/images/help/hello-1.jpg' . How can I use the image path associated with an http: // without ng-src instructions on an Android phone? My HTML: $ location is the possible solution ()? & lt; Div ng-controller = "helloCtrl" class = "slide-container" & gt; & Lt; Div & gt; & Lt; Carousel Interval = "My Interval" & gt; & Lt; Slide ng-repeat = "slide in slide" active = "slides. Active" & gt; & Lt; Img ng-src = "{{slide.image}}" style = "margin: auto;" & ...

Storing 2D arrays within a 2D array - Python -

I have two 2D arrays, each containing information containing each layer: Layer0 = [[information], [information]] layer 1 = [[information], [info]] I would like to place these two 2D arrays within another array: However, my program will not display tiles properly. My question is this: Do store 2D arrays within any other 2D array possible? Thank you. I have a fixed loop system, which is said to run again via an array and display the tile according to the array content: For maplayer: For tiles in array: If tile == 0: Screen. Bleet (Self-Tile_Dict [0], (self.tileX, self.tileY) self.tileX = self.tileX + 16 if tile == 1: screen.blit (self.tile_dict [1], (self.tileX, Self.tileY) self.tileX = self.tileX + 16 self.tileX = self.cameraX self.tileY + = 16 I have tried to repeat through the actual map array For another simple, adding pipes, but PyGame displays the blank screen: for maplayer: for array in codelayer: for tile in array: if tile == 0: Screen. Bleet (white Ti...

regex - Java - Remove all non word characters of a string for all languages -

I need to remove all punctuation marks in words in Java. System Out .println ("do., ​​This". ReplaceAll ("[^ \ \ w]", "")); System.out.println ("scan") .replaceAll ("[^ \ \ w]", "")); But it will not work with kyrillic or other languages. I have already tried to work with \ p {punct} , but the list is not complete, for example "and» is unavailable It is not certain that where \ p {wd} stands for any non-word character in any language. P {wd}

c# - Multiple instances of EF 5.0 DbContext Concurrency -

I am trying to simulate a scenario with many different applications accessing my database. The way I am doing this is making 10 different threads, which makes some concurrent transactions and thus an example of my DbContext in each thread. The problem is, DbContexts do not know about updates in other instances, so my question is, how can I ensure that there is no data incompatible with my DBCTtex? If you use any level of segregation except the serial jab, then some levels of incompatible data At risk. In case of serial performance, it is expensive and used only in very specific circumstances. Securitization specifies the following: Details can not read data that has been modified, but not yet committed by other transactions. Any other transaction can modify the data read by the current transaction until the current transaction is completed. Other transactions can not incorporate new rows with key values ​​that fall into the category of keys read from any statement in the ...

ios - Fetching only Core Data objects that share a value for a particular attribute -

I have a core data object that has many attributes, one of which is called a category. It is a string that can be taken at any price, nothing is guaranteed that I have any knowledge of the front. I will run a fetch that will return a list of category values ​​that are shared in all stored elements whose tag values ​​match a given value. I'm not sure how to best describe, here's an example: item number tag category ------------------- - ------------ 01 AAA Red 02 AAA Green 03 AAA Blue 04 BBB Blue 05 BBB Red 06 BBB Yellow 07 CCC Blue 08 CCC Yellow 09 CCC Red I want to keep the results of my fetch as a list of all the categories that are shared in all objects whose tag set {AAA, BBB, CCC }, Who will return ["red", "blue"] in this case, because they are only one of those categories which is shared between objects, whose tag is in the set set. I hope to find something as fast as possible, because when this app runs on any real project, there will be t...

type conversion - Two experiment variations do not appear in the table (Google Analytics) -

Image
I have started running a test After a few hours (3-9), I get a data under the "Conversions" section Capture not found. But I can see data from some experiment sessions under "Site Usage". Even I have verified for both pages. Experiment Code Verification Basics: Found the Google Analytics code found in the experiment code. Fake footer v1: Google Analytics code. Please check the attachment Note: I have had some problem with another problem like this. In that examination, I can see the data under "conversion" a day later. It does not often display data in a few hours. Can you please help me to solve this problem? Thank you, Gopal I had a similar problem. I have set a test, an alternate page and a goal set. mysite / xavier mysite / magneto mysite / t-rex Xavier is my test page, Magneto is my option, and T-Rex is my goal. I am using Drupal, so I installed the Google Content Experiment module: This gives you a field on each conte...

ruby on rails: how to change the routing address -

I am new to the rail and I would like to know that if there is any way to change the names of the routes, I will be punished in one minute. I will explain I have named a Administrator users_controller and below is the code that is in my controller: if def can create @ User.save redirect_to @user end and my routes.rb file is given below: Resources: Users For '/ user / receive: ID': 'user #show' Now assume that I have a form and I fill it correctly if I Localhost: 3000 / users / id (id = some value) What I do now I want this URL like localhost: 3000 / registered . This is when I click the submit button and if everything is correct then I should see the URL as localhost: 3000 / registered which shows me my show action or that just works like localhost: 3000 / user / id (id = some value) . I do not want that ID to be visible. For this, I tried get 'registered', to: 'users # show' but still me localhost: 3000 / users / id (i...

Adding scores to game using cocos2d-x -

I am making a game in cocos2d-x and I am trying to add scores to my game. First I declared a score variable and set the value to 0. While doing this, while using the loop I used the loop in the value of 1, and showed me the score using printf but it is not working. Please help me with some code. Int Score; Socrates = 0 {printf ("% d", score); } While (score> = 0) If you have your score graphically Make a cocos2d :: Label , see the documentation. Set its value: label-> setString (Std :: to_string (score)); addChild (label, 1); In your layer code where it is understood. label-> Set-position (...) There are several types of label types and constructors that you can use, look upwards Use: This is a simple example using one of the consultants given here: cocos2d :: LabelBMFont * label = cocos2d :: LabelBMFont :: create (std :: to_string) (Score), "marker imposed"); Label-> SetAlignment (Cocos2d :: TextHAlignment :: center);...