Posts

Showing posts from May, 2014

Wordpress: update all field values? -

I want to update all the field values ​​(custom fields) of a specific value. You want to create it like a function and it is run on a specific page or by clicking the button. Is it possible? look at a selection of custom keys and their values ​​can be added to WordPress, where custom keys and The cost of allocating a fixed post is based on the cost per post. EDIT: Try to see if it helps you to administer your fields.

Getting data for more than 1 categories in SQL Server -

There are some categories and its products but the products are used for other categories. For example, "Metal Handles" are categories and used for "metal handles", but it is used for "children's handles" as well thanks thanks Div> really understand Not coming that you really need three potential cases here: Products and categories - Many for many relationships In many relationships Solve many You need three tables for the field / P> Categories (ID, Category name) categorymap (cd, partoffcigb) product (id, product name, category id)

objective c - Setting default application for given file extension on Mac OS X from code -

I have a list of applications for file extensions (by using LSCopyApplicationURLsForURL) I have one of the above calls I want to change the default file association with the code to choose from. Is there any way to do this? Here is the snippet of code for a very relevant task: set your given file extension As the default application to you: #import & lt; ApplicationServices / ApplicationServices.h & gt; #import "LaunchServicesWrapper.h" @implementation LaunchServicesWrapper + (NSString *) UTIforFileExtension: (NSString *) extension {NSString * UTIString = (NSString *) UT touch creole reversed identifier (KUTTagClassFilenameExtension, (CFStringRef) extension, NULL); Return [UTISTing Autourage]; } + (BOOL) setMyselfAsDefaultApplicationForFileExtension: (NSStatus *) File Extension (OSStatus returnStatus = LSSetDefaultRoleHandlerForContentType) [UTIFile Extension: File Extension on Launch Services], KLSolarLL, (CF Stringerf) [[NSBindal Main Bundle] Bundle Iden...

python - Why does the istitle() string method return false if the string is clearly in title-case? -

Return to true, if the string title is a categorized string and has at least one letter, for example uppercase letters can only obey untold characters and lowercase letters. Otherwise return false. But in this case it returns false: gt; & Gt; Book = 'every programmer should know' & gt; & Gt; & Gt; Book.title () 'Every Programmer Should Know' & gt; & Gt; & Gt; Book.istitle () Wrong What am I missing? The title of the method () is not to change the string (telegram is irreversible in Python) This is a new string That you have to assign to your variable: & gt; & Gt; & Gt; Book = 'every programmer should know' & gt; & Gt; & Gt; Book = book.title () & gt; & Gt; & Gt; Book.istitle () is true

php - Database: Sorting hierarchical data (Modified Preorder Tree Traversal): How to retrieve immediate children -

I am using MySQL with PHP; Principle 2. My question is assume that I am using it, is there any way I can only get immediate children? In addition to LFT and RGT values, you can also store the original ID of each child. One advantage of doing this is that if you have a problem with your LFT and RGT values ​​then you can make the tree again. This allows you to set up immediate children's parental nodes right away.

c# - Visual Studio 2008 Publish failed view log -

There is no error or warning on my VS2008 web application project, but when I try to publish it fails it happens. How can I view the VS2008 published log? All messages generated during a publish are written to the output window bus output window (view -> Output or Ctrl + Alt + O) and you can see both messages during and after the publication process.

bit manipulation - Fastest way to read Left-Most bit from unsigned int (C++)? -

What is the fastest way to read most bits from unsigned int? Thanks, Online SW i & gt; & Gt; (Size (unsigned integer) * CHAR_BIT - 1) sizeof , multiplication and subtraction will be computed by any appropriate compiler at compile time, so it is a single The right-shift instruction should be made, the faster you can get it.

jquery - ASP.NET MVC: Redirect user to route with parameters from a drop down list -

I have a drop down list ( & lt; select & gt; tags) ). When a user selects a bike in the list, then I want them to be sent to the details page for the selected bike. I have a route for motorcycle details such as: routes. New route ("bike details", "bike / {likeid}", new {controller = "bike", action = "description"}, new {bikeId = @ "\ d +"}); What's the best way? I'm thinking that I should use the URL for drop down list item values ​​and then use JQuery to redirect to the selected URL. But before dealing with the old plain ASP.NET, I can not help but I think the people of Microsoft have thought of something cleverly for such scenarios. Appreciate any thoughts! to select it, Change events, but there is a button which triggers the redirect some browsers , Especially using the screen reader, do not behave well with the event of change - you are firing for each item while scrolling, because it is taking...

c - Correctly sizing Alsa buffers, weird API -

I am currently working on a project for which I have to do some sample with Alsa. I am trying to configure, but how am I determining my reading size correctly? There are two priorities which are interesting to my work: The name of the first one tells that the output will be a period of time for a sample period, although it is weird: If I am setting sample rate on F = 44100Hz should be in the sample duration (in nanosecond) T0 = 1e 9/44100 ~ = 22676 ns while the function answers T1 = 725 us = 725000 ns . In the meantime, even I have been asked to use non-locking primitives, even if I am trying to lock the 'readi' time profile, and this It is known that for the sample T2 = 8028603 ns in the worst case and T3 = 12436217 ns in the worst case. In the end, I do not know what it means to the following two: snd_pcm_hw_par Ams_get_buffer_time snd_pcm_hw_params_get_period_size I buffer in time and How to measure the duration of the shape, however, returns the ...

visual studio 2008 - Setting a password for a DB in SQL 2005 -

I am writing a program in VS 2005 and I want to control access to one of DBS in SQL Server 2005 (Express). I mean, I do not like other applications to connect to this server, use of data in this DB Please. What can i do View in App Roles After playing a role, passwords for the application to set that role Have to use. After that you have to restrict everything to your database in that role. Users will still be able to connect themselves, but they will also log in with the application role. with password password = 'password'

asp.net - Register stylesheet from web control on page with UpdatePanel -

What is the best way to register a stylesheet once on the page with a customer web control? Please keep in mind that the page uses an UpdatePanel for async calls. I just tried putting & lt; link & gt; Tag in ScriptManager.RegisterClientScriptBlock (), but I get this error: The script is registered for the type 'myControl' type and invalid in the key 'Mikey' outside the script tag Characters are: Only properly formatted script tags can be registered. If I try to add to the page by adding it to the control hierarchy, it appears once for each instance of your control on the page. Well, that's where I went with. I decided to build the extension methods, which will include the link. Update: I had to change the ScriptManager extension because it was still not playing well with UpdatePanels, the updated code is below. & lt; System Runtime COMPLETER SERVICES Extension () & gt; _ Public Sub RegisterStylesheetInclude (as ByVal scriptMana...

Is there a way to not use the traditional .config files for ASP.NET? -

Let me know the web. Configure xml get beautiful verbose. Do you like any initiative edit : I already know that the FubuMVC Web Framework, built on top of ASP.NET , Which enables cleaner config files using YAML, or .rb files? , Tries to reduce too many XML to put you into that file to work properly. But it is still very ugly, I find it unnecessary: ​​ & Lt; / Assemblies & gt; & Lt; / Compilation & gt; & Lt; Authentication mode = "none" /> & Lt; CustomArror mode = "remote-only" /> & Lt; Pages & gt; & Lt; Control & gt; & Lt; Add tagPrefix = "asp" namespace = "System.Web.UI" assembly = "System.Web.Extensions, version = 3.5.0.0, culture = neutral, publicKeyToken = 31BF3856AD364E35" /> & Lt; Add tagPrefix = "asp" namespace = "System.Web.UI.WebControls" assembly = "System.Web.Extensions, version = 3.5.0.0, culture = neutral, publicKeyToken = 31BF385...

c++ - can i calculate normals in gpu? -

I have an OpenLL application that loads a dxf and pulls it on the screen, every time I have a normal section Is there a way to calculate the normals in the GPU rather than CPU? if so? Yes, this is possible. Would you like to learn about shaders?

android - Is there anyway to bypass 'Unknown sources' setting without having the application actually downloadable in the market? -

Is the app to bypass the 'Unknown source' setting without really downloading it into the market? It is okay to sign up for the market, but I do not want to actually get the applications available through the market due to partner restrictions. However, the installation must be smooth to allow the user to install applications without market. no The complete issue of "Unknown Sources" setting is to clearly stop what you are trying to do. (Or at least, I really hope there is no way to get this setting left. Security setting is configured to prevent users from being able to install unwanted applications on their phones. Do.)

php backslash find and replace -

I am trying to do a simple search and am changing it within a string: $ Share_name = str_replace ("", "\", $ share_name); Unfortunately for some reason it replaces all the spaces with "\\" instead of "\" instead of "\". Does anyone know what is going on and how to solve this problem? I think you mean: $ share_name = Str_replace ("", "\\", $ share_name);

What is the best way to implement notification in a C# web application? -

What is the best way to implement information in the C # web application? If this was an EAI BPL application, then I would use the facility of information within the BPL specifications so that I can emit events on those major tasks which I want to monitor. Since this is a C # web application, what are the architectural options? Should I drop messages via pub / sub, which I will keep watching or I should use NSSRsbis, or want to monitor me or use net event handling to use me. I care about those two methods or I am a mixture of them or there is no alternative. I am trying to optimize with maximum optimization and scalability, at least the code is Event aggregator pattern is a great way to use for things like this: You can check the KiGG project: There is a very good implementation in it. Areas that they can make it a little improvement but overall I like it.

c# - DirectX DirectInput won't detect connected devices -

I'm trying to use a joystick in my C # WPF application using DirectX (Microsoft.DirectX .DirectInput;), but for some weird reasons I get an error in the first line, where I try to find out all connected devices. I have all the application codes in the constructor so far: DeviceList gameControllerList = Manager.GetDevices (DeviceClass.GameControl, EnumDevicesFlags.AttachedOnly); The error is as follows: Error type: XamlParseException was unmanaged. Error message: The constructor's voice on the "joystick test. Manwindo" type matches the specified compulsive barriers, threw an exception. 'Line number' 3 'and line position' 9 '. " I am working with this example that I found online: My current setup is WPF, C #, .NET 4.0, and Windows 7 64-bit Here's late for the party but it's actually a bit darker to say it Are there. This is not controversial because you are using Direct In-Output Assembly (1.x) which puts your applic...

css - vertical aligning text within dropdown or text input? -

I have text input and selection boxes at 40px width ... I want text within these elements of the input field Bottom half I have been successful in setting up Firefox (but Safari or Chrome) with padding top. I need this to work for Safari and Chrome, however, these browsers automatically align texture in vertical center. Is this the solution? Thanks! You can use your padding code. To work it in Safari / Chrome / Opera, add line-height: 40px (or any height in your area) All browsers then recognize padding.

header - how to make sure POST data comes from specific domain? -

I have a page confirm_payment.php Getting mail data from other pages. How can I ensure that this post data comes from a specific domain only? I can not trust the IP address as if it can change in my case I want to avoid "fake" submissions from my "confirm_payment.php server side code". Without going into details, it is to ensure that my page receives the confirmation of the hosted page from the payment gateway and the confirmation is valid. John Condi gave a great explanation about how to solve your problem : If you need more information, please go back to your original question.

css - IE7 child elements not filling parent -

मेरे पास इस तरह की संरचना है: & lt; ul class = "control tabSet बटन ऊर्ध्वाधर "& gt; & Lt; li वर्ग = "पहले टैब" & gt; & Lt; बटन वर्ग = "बटन ऊपर" id = "source" & gt; & Lt; span class = "wrap" & gt; लेबल 1 & lt; / span & gt; & Lt; / बटन & gt; & Lt; / li & gt; & Lt; li वर्ग = "टैब अंतिम" & gt; & Lt; बटन वर्ग = "बटन ऊपर" id = "save" & gt; & Lt; span class = "wrap" & gt; लेबल 2 & lt; / span & gt; & Lt; / बटन & gt; & Lt; / li & gt; & Lt; / ul & gt; सभी ब्राउज़रों में, आईई 7 को छोड़कर, .बटन तत्व की चौड़ाई को 100% तक सेट करके, मुझे यह व्यवहार मिलता है कि हर बच्चे के रूप में व्यापक बच्चे हैं (जैसा कि निर्धारित होता है वाइप तत्व के अंदर का पाठ)। मुझे माता-पिता की चौड़ाई निर्धारित करने की आवश्यकता नहीं है; यह सबसे बड़े बच्चे की चौड़ाई के आधार पर ब्राउज़र द्वारा निर्धारित किया जाता है। आई...

Selenium - can it test a B2B web service -

I have used selenium to test many UI from the browser. If you have a web service behind the Java SSP page, i.e. in the servlet, you can test it with selenium. Selenium can be used to test the B2B web service i.e. backend is not a browser UI component? I used Sopia to do such tests in the past but our test department is trying to standardize Selenium. You can do but I will not recommend it. If the page is returning XML, then you will not be able to use standard selenium calls to verify what is happening because you will not have access to the DOM. If the returned plain text for Javascript you will struggle with the output check. This is a definitive case for using the right tools for the job and Selenium is not the right tool for web services testing. I will use soap UI or just use some URL library to call service URL and then confirm the result. If they are looking for standardization then their purpose is to standardize the equipment. Soen for selenium, unit and integ...

null reference exception was unhandled C# -

निजी शून्य StartReadInlay2 () {बाइट [] सीएसएन = नया बाइट [8]; बाइट [] sw12 = नया बाइट [2]; String strsw12 = "", errdes = "", परिणाम = ""; Test1_2 = नया प्रारंभ (); Test1_2.logmode = कन्वर्ट.ToInt32 (कॉन्फ़िगरेशन सेटिंग्स। AppSettings ["LogMode"]); Test1_2.iChipType = GetChipType (lblChipType.Text.Trim ()); // - प्रारंभिक परिणाम का परीक्षण = test1_2। प्रारंभ (1, ** configXML.fnSamSlot **, configXML, रेफरी सीएसएन, रेफरी प्रगति 1_2, रेफरी lprrocess1_2, रेफरी स्वा 12, रेफरी एरेडेस); ScSN1_2 = Hex.ToHexString (test1_2.chipID); Strsw12 = Hex.ToHexString (sw12); अगर (strsw12.Equals ("0000")) errInlay1_2 = परिणाम। टॉस्ट्रिंग (); अन्य errInlay1_2 = परिणाम। टॉस्ट्रिंग () + strsw12; LProcess1_2 = 2; अगर (! ErrInlay1_2.Equals ("")) StatusInlay1_2 = false; Else StatusInlay1_2 = सच; } शुरुआत के लिए आपका पूरा कोड उदाहरण सी # में है और निश्चित रूप से उड़ा जाएगा अगर आप VB.NET अनुप्रयोग लिखने का प्रयास कर रहे हैं।

Parallel programming in Java -

How can we do parallel programming in Java? Is there any special framework for this? How can we do the stuff? I will tell you what I want, I think that I am developing a web crawler, there is a lot of crawl on its website from the Internet, crawling a system will not make things work Appropriate, so we need 1000 systems to work, if this is the case then can I implement parallel computing? Can you give me a proper example? parallel programming i.e. concurrently programming, then you are certain This is a thread-safe implementation of MPIJAVA and it supports both distributed and shared memory models. I tried to do it and found very reliable. 1 Import MPI. *; 2 3 / ** 4 * Compiled: Impl Ment Specific 5. Execute: Impression Specific. 6 * / 7 8 Public Class {9 10 Public Stable Zero Main (String [] Send ARG) Exception {11 12 MPI.Init (args) throws; 13 14 integer rank = MPI Comm_World Rank (); // Existing Process: 15 Integer Size = MPI .comm_word. (); Total number of 16 proces...

IVY - Set the default transitive value -

आप IVY में संक्रमणीय के defalut मान कैसे ओवरराइड करते हैं? मैं यह मान रहा हूँ कि आप अपने ivy.xml में निर्भरता घोषणा की क्षणिक निर्भरताओं को डाउनलोड करने के लिए आइवी नहीं चाहते हैं फ़ाइल? विकल्प 1: ट्रांसमिटिव पैरामीटर (ivy.xml) & lt; निर्भरता org = "foo" name = "bar" revision = "3.0 "संक्रमणीय =" गलत "/ & gt; विकल्प 2: कॉन्फ़िगरेशन मैपिंग (ivy.xml) यदि बार मॉड्यूल को एक मेवेन रिपॉजिटरी में रखा गया है, तो मास्टर स्कोप में डिफ़ॉल्ट कॉन्फ़िगरेशन मैप करने से अन्य निर्भरता & amp; lt; निर्भरता org = "foo" name = "bar" संशोधन = "3.0" conf = "default- & gt; मास्टर" / & gt; विकल्प 3: पीओएम फ़ाइलों (ivysettings.xml) में जानकारी का उपयोग न करें जब मेवेन रिपॉजिटरी से डाउनलोड किया जा रहा है तो यूपीएसफ़ॉर्म पैरामीटर को गलत रूप से सेट करना मॉड्यूल की उपेक्षा करेगा निर्भरता & lt; ibiblio name = "maven" m2compatible = "true" usepoms = "false...

SQL LIMIT return 'zero' - 0 - rows(IN PHP) -

I have an error in this query, when the query returns zero rows Error number: 1064 There is an error in your SQL syntax; Select pl.name, pl.email players from pl players_bonus pl to pl pl at pl pl Check the related manual for your MySQL server version for the correct syntax to use on pl. Id = pl_b.id_player WHERE pl_b.id_bonus = 3 LIMIT -20,20 My way is: public function getPViews_num_rows ($ limit = array (0,20), $ page_num = 1, $ id) {$ limit = "LIMIT {$ border [0]}, {$ border [1]}"; $ sql = "Select pl.name, pl.email players at pl.id = pl_b.id_player Add players_bonus pl_b at WHERE pl_b.id_bonus =? {$ Limit}"; $ Where = array ($ id); $ Query = $ this- & gt; Db- & gt; Query ($ sql, $ where); Refund $ query-> Num_rows (); } I do not want to do another query to calculate the rows before querying this Thanks for the reply. You can not specify negative LIMIT -20,20 This means that you want to return back to 20 rows startin...

c# - How to convert Untiy Configuration from 1.2.* to 2.0.* -

यूनिटी 1.2 में, मुझे web.config में यह टेक्स्ट था & lt ; प्रकार प्रकार = "आईआरवाट्राइजिस्ट्री" मैप = "टाउनहॉल.एमवीसी। रूटिंग। टाउनहॉलरेउट्स, टाउनहॉल.एमवीसी" & gt; & Lt; टाइप करें कॉन्फ़िफ एक्सटेंशन टाइप करें = "माइक्रोसॉफ्ट। प्रैक्टिस। यूनिवर्सिटी। कॉन्फिगरेशन। टाइप इंचार्ज एलेमेंट, माइक्रोसॉफ्ट। प्रैक्टिस। यूनिट। कॉन्फिगरेशन" & gt; & LT; निर्माता & gt; & Lt; परम नाम = "मार्ग" पैरामीटर प्रकार = "मार्ग संकलन" & gt; & Lt; निर्भरता का नाम = "एप्लिकेशनरूट कलेक्शन" / & gt; & Lt; / param & gt; & Lt; param नाम = "मार्गहैंडलर टाइप" पैरामीटर प्रकार = "सिस्टमटाइप" & gt; & Lt; निर्भरता नाम = "रजिस्टर रौन्डहैंडर" / & gt; & Lt; / param & gt; & Lt; param नाम = "सेटिंग्स" पैरामीटर प्रकार = "IAppSettings" & gt; & LT; निर्भरता / & gt; & Lt; / param & gt; & Lt; / निर्माता & gt; & L...

iphone - A question related to UITabelViewCell -

How to set the background image of UITabelViewCell? I want to help the image of each cell in UITabelview help in this situation Adding custom cell Set image to image in image view background image view

Mixing Objective C and C in switch statement trying to add a subview iphone SDK -

I have a strange problem. I have a loop in my loop, there is a switch statement inside the I loop counter one pointer Which indicates the beginning of an initial array, until it gets "Terminator number", it increases, the seen array is used to create a view, to put each element in a view Represent SubViews. Here's the code: for (self.composizon; * composizione> gt; kFine; composizione ++) {int c = (int) * composizione; NSLog (@ "% d", c); Switch (C) {Case kForchettaPesce: Case kForchettaNormale: {NSString * imagePath; ImagePath = [[NSString alloc] initWithFormat: @ "% @ /% d.png", [[NSBundle main bundle] resource path], C]; UIImage * image = [[UIImage alloc] initWithContentsOfFile: imagePath]; [Imagepath release]; NSLog ("pippo" @); UIImageView * imageView = [[UIImageView alloc] initWithFrame: CGRectMake (0, 0, image.size.width, image.size.height)]; ImageView.image = Image; [Image release]; [Self.view addSubview: imageView]; [See im...

iphone - how to change the base sdk to 3.0 -

I have developed a project for a base SDK 3.0 and now I have installed xcode3.2.3. Now when I'm trying to build my project this SDK 3.0 is missing. And when I'm trying to set the original SDK from project settings, there is no 3.0 sdk available in the list. Only 4.0 is available. So my question is how can I add a 3.0 SDK to the new ExCode version? Thanks in advance. You can not do this with the new XCode, but you can build the base as SDK with 4.0 And you can set the "iPhone OS deployment target" in your target settings to the lowest OS version that you want to support.

java - What are the minimum dependencies and plugin configuration I need to create a web service client using Axis2 and Maven from a WSDL file? -

I am trying to create a web service customer using Axis2. I want to use Maven 2 to generate the required sections from WSDL, but the documentation for the wsdl2code plugin is not helping me whether anyone has a basic palm Example of XML, which will generate class from WSDL? Maybe you can help. This should be the main player and you can add a pum entry like this for: & Lt; Version & gt; 1.5.1 & lt; / Edition & gt; & Lt; / Dependencies & gt; Meowen sensory dependency should then cover the rest.

sql - Correct form long time query executing myodbc syntax -

I am trying to create a SQL query for access to recover data from the Internet that myodbc connection , But the time to complete the query is too long, so I think the problem is with the query: SELECT COUNT ([o]. [Order_id] ) Asmany_orders, (SELECT SUM (.. [OP1] [products_quantity]) OT1 from orders_total, as order O1, orders_products OP1 ou [O1] as a In the form [date_purchased]> date =) - 30 and [O1] [orders_id] = [OP1] [... orders_id] and [OT1]. [Orders_id] = [OP1]. [Orders_id] and [OT1 ]. [Class] = "ot_total" and [O1]. [Orders_status] = 1 and [OP1]. [Products_id] = [session]. [Products1] [products1] [product_id] group [op1]. [Products_id]) pediant, [op] . [Products_model], Goal ((7 + 1) * (howmany_orders / 90)) + 1) - (P. Stock_AL- IIF (Pendetta> 0, Pendiantie, 0)), 0) AS Peder, order_tatal AT from PR_ID, According to the order, Inner Join product as order-products at mid-end ([op]. [Products_model], 4) such as p.ref_id where [o]. [Date_purchased]> gt; Date...

Debugging in Visual Studio -

What is the difference between debugging and debugging in a video studio while running a program? The first option is to start the program under the control of the studio's debugger. The second option program is stand alone. There are some practical differences during debugging the process: You can stop the debugging process from the video studio, resume, stop, and restart. Breakpoints defined in the code remain active for the debugged process, and the debugger will stop the process and whenever the one affects them, the stack will show the trace. You can not get out of Visual Studio without dropping the debug process. When a debug console exits from the process, it will display an end message unless you press any key. This allows you to inspect the console window output without the need to finish the process immediately.

How to "add existing frameworks" in Xcode 4? -

I can not find the good old "Add existing framework" option How do I do this? We are talking about Exode 4 DP2 (In terms of iPhone development, as far as this is important ...). In Project Navigator, select your project. Choose your goal. Select the " Build Stages " tab. Open the link binaries with libraries Click the + button. Select your framework (optional) / Em> Drag and drop the structure added to the " framework " group.

c# - How to remove DateTime.Parse dependency on System.Threading.Thread.CurrentThread.CurrentCulture -

पर विचार करें निम्नलिखित कोड: वर्ग कार्यक्रम {static void मुख्य (स्ट्रिंग [] args ) {Try {System.Threading.Thread.CurrentThread.CurrentCulture = new CultureInfo ("Fo-FO"); Var s = DateTime.MaxValue.ToString ("yyyy-MM-ddTHH: मिमी: ssZ"); Var d = DateTime.Parse (s, CultureInfo.InvariantCulture); कंसोल। WrightLine ("एफओ-एफओ के साथ पार्स करने में सक्षम था"); } पकड़ (अपवाद ई) {Console.WriteLine ("अपवाद: {0}", ई); } {System.Threading.Thread.CurrentThread.CurrentCulture = new CultureInfo ("en-US") का प्रयास करें; Var s = DateTime.MaxValue.ToString ("yyyy-MM-ddTHH: मिमी: ssZ"); Var d = DateTime.Parse (s, CultureInfo.InvariantCulture); कंसोल.प्रकाशलाइन ("एन-यूएस के साथ पार्स करने में सक्षम था"); } पकड़ (अपवाद ई) {Console.WriteLine ("अपवाद: {0}", ई); }}} आउटपुट है: अपवाद: System.FormatException: स्ट्रिंग को मान्य दिनांकटाइम के रूप में पहचाना नहीं गया था। DateTimeTest2.Program.Main पर System.DateTime.Pars...

vb.net - Running powershell scripts from within a .NET windows app -

I'm going to need to run the script from within a vb.net windows application. I found the script background right; Runspace = RunspaceFactory.CreateRunspace () Using MyPipeline.Commands.AddScript MyRunSpace as using MyRunSpace.Open () MyPipeline pipeline = MyRunSpace.CreatePipeline (AS) ( "Import modules -name "& amp; moduleName & amp; vbCrLf & amp;" (the module -name "& amp; moduleName & amp;") .version ") with the use of the end result of lackluster results = MyPipeline.Invoke () ' Do something using MyRunSpace.Close () end However, I now need to be able to do powerhell runs (not in the background) such as When signs are found; set ExecutionPolicy unrestricted If you see I'm currently seeing in Microsoft.PowerShell.ConsoleHost name space I can use something like; dim config = RunspaceConfiguration.Create ConsoleShell.Start (config, "Windows PowerShell", "", New String () { "...

Cocoa Touch - Text Boxes Question -

I have the image of a chalk board and I want to write it on the chalk board so that the text is invisible in the box but still Working .... Any ideas how can I do this? You can change the background color property of this text box [UIColor clearColor] .

c# - Annotations on interfaces -

क्यों एनोटेशन इंटरफेस में काम नहीं करते? जैसे: सार्वजनिक इंटरफ़ेस IUser {[आवश्यक] स्ट्रिंग प्रथम नाम {get; सेट; }} अब अगर मैंने इसे लागू करने के लिए एक क्लास बनाया है तो सार्वजनिक आंशिक क्लास ग्राहक: IUser {सार्वजनिक ग्राहक} () {} सार्वजनिक स्ट्रिंग प्रथम नाम {प्राप्त करें ; सेट; }} जब तक मैं वर्ग में संपत्ति को भी चिह्नित नहीं करता हूँ, यह सत्यापन को लागू नहीं करेगा! तो पहली जगह से इंटरफ़ेस में इसे एनोटेट करने का क्या मतलब है! ! तो किसी भी विचार? अच्छा, इसका सरल उत्तर यह है कि है नहीं अंतरफलक में टिप्पणी में इंगित करें जैसे आपने नोट किया है, विशेषता को कॉल करना.गेटअट्रिब्यूट () (भले ही वारिस सत्य है) संपत्ति पर गुणों को वापस नहीं आती है जो आपके क्लास ने कार्यान्वित की है। संभवत: इस तरह की सुविधा का समर्थन करने से एक ही कार्यान्वयन से कई इंटरफेस संतुष्ट हो जाएंगे।

c# - Assignment in constructor vs direct assignment -

This morning a basic question arose in my head. Here's what: There is a difference in doing this: Public class mylas {private object _myField = new object (); ...} and do the following: public class MyClass {private object _myField; Public MyClass () {_myField = New Object (); } ...}} Just to display ... using the system; Public Essential Class Base Class {Public Base Class () {Console.WriteLine ("Results for {0}: {1}", GetType (), Colledbink Constructor ()); } Protected abstract string collidebconstructor (); } Public class convertible initiator: base class {private string foo = "foo"; Safe override string calledByConstructor () {return foo; }} Public class builder start: base class {personal string foo; Public Constructor Initialization () {foo = "foo"; } Safe override string calledByConstructor () {return foo; }} Public Sector Exam {Fixed Zero Main () New Constructor Start (); }} Here the original class creator calls the a...

report - Is OpenReports compatible with Java 1.5? -

ओपनरपोर्ट्स के लिए जेडीके 1.5 या अधिक की आवश्यकता है। हालांकि, एएनटी बिल्ड के बिंदु तक निर्देश, मैं निम्नलिखित त्रुटि को देख रहा हूं: [javac] C: \ My दस्तावेज़ \ संदर्भ \ बीआई उपकरण \ openReports \ openreports-tomcat \ openreports \ Src \ org \ efs \ openreports \ engine \ queryReportEngine.java: 36: org.displaytag.tags.ColumnTag [javac] खराब वर्ग फ़ाइल का उपयोग नहीं कर सकता: C: \ My दस्तावेज़ \ संदर्भ \ बीआई उपकरण \ OpenReports \ openreports-tomcat \ Openreports \ WebRoot \ WEB-INF \ lib \ displaytag-1.2-patched-for-itext-2.1.0.jar (org / displaytag / tags / ColumnTag.class) [javac] वर्ग फ़ाइल में गलत संस्करण 50.0 है, 49.0 होना चाहिए [ Javac] कृपया निकालें या सुनिश्चित करें कि यह क्लासपाथ की सही उपनिर्देशिका में दिखाई देता है। [Javac] आयात org.displaytag.tags.ColumnTag; [Javac] ^ [javac] 1 त्रुटि "ग़लत संस्करण" संदेश को गॉगल करने के बाद, ऐसा प्रतीत होता है कि क्लास जावा 1.6 के लिए विशिष्ट है। तो - इस सवाल का शीर्षक बताता है - क्या किसी को पता है कि ओपनरपोर्ट्स ...

objective c - Problem opening a page in different UIWebViews using Javascript -

I'm with the majority of the functionality being a web application, an iPad app. UI has only three UIWebViews which load pages. Every clicked link has been paused, and I have a request variable in the URL named "iPadTarget." Ex: The above code is the second open webview because iPadTarget = 2. (UIWebView *) WebView shouldStartLoadWithRequest: (NSURLRequest *) request navigationType: (UIWebViewNavigationType) navigationType {- (bool) WebView : The code that caters NSURL * Url = [request URL]; // Remove the value from the 'iPad tabs' request variable in the URL string. NSString * test = [url query]; Int Index = [Test Rangeoffestring: @ "iPad Target ="] place; Int target = index + 11; Four c = [test character atindex: target]; NSLog (@ "% c", c); If (navigationType == UIWebViewNavigationTypeLinkClicked || navigationType == UIWebViewNavigationTypeFormSubmitted || navigationType == UIWebViewNavigationTypeOther) {if (c == '1') {...

javascript - Mapping of jQuery functionality to YUI 3? -

I have a project that is using both jQuery 1.3.2 and YUI 2.6, and this one or the other. I have a lot of developers who love jQuery and can not live without it, but I think some features of YUI 3 are a better fit for the project (like base widget). I was trying to find the mapping of functionality between JQuery and YUI 3, and found, which compares YUI 3.0.0 from jQuery 1.4.2. I'm looking at YUI 3.1.1 or 3.2.0 preview, and wonder what other resources are there? For a brief moment, I had to write the adapter / shim layer, but it seems that it will only confuse this issue and developers are better off working in a pattern or the other. Update: I think the above content has been migrated, and "YUI team has graciously captured the maintenance." It now compares jQuery 1.4.2 and YUI 3.1.2 Carlos Rossetta Stone Good source is the facility to compare the two libraries of the facility, if you look at the impurities due to the development of YUI since 3.0.0, then Car...

google analytics - Track incoming Referring site via link in PDF file? -

I recently placed an advertisement in a weekly publication that sends a PDF file. My ad is directly connected so that the reader can visit it on his website by clicking on it. The PDF file is hosted on a different server, but in fact, there is a PDF file that should be downloaded and viewed on that site; Emails will not be shared or shared. I have Google analytics and some other data tracking programs are installed and I can not see reference URLs from this other site in some other way. Is there anything that I can ask the designer of the PDF file that he is able to track them to link? Or is it just not possible? Use Google Analytics campaign tagging This tool sets it up will help. You want to classify variables such as source and medium set, at minimum For example, if you have a URL, you can set the parameter as follows: utm_source: BlahNews utm_medium: newsletter utm_campaign: july10issue Your resulting URL will Google Analytics will track these hits within that ...

user interface - Android - How to make UI look same across devices? -

There are several types of tools on the market, with different screen sizes, resolutions, and pixel density. There are some layout preferences or tips / tricks that are usually meant to ensure that the app looks the same across all devices? I always have a "dip" form of stand alone unity instead of pixels Use layout_weight to create ratio, and all my apps, with full 10 inch tablet devices and small smartphones, a 3,2 inch screen!

java - Instance variable of Activity not being set in onPostExecute of AsyncTask or how to return data from AsyncTask to main UI thread -

I am trying to find the right way to create an asyncTask to get some data from the internet and then take it To pass the data and bundle it in an intent and for a new activity (a list display). Therefore, in the first activity, I have only one edit text and button. In the event of an OnClick, the job should be called and when it is complete, the data should be bundled inside the intent and the next activity should be passed. The problem occurs when I take the results on poststation and set them in an example variable of main activity, this task is complete when the task is completed. Here's the barebones version of code: The public class uses SearchActivity Activity OnClickListener {Fixed last stringTAG = "SearchActivity"; Private Editing Test Search Input; Private Button Search BTN; Private site list places; /** Called when the activity is first created. * / @ Override Crate on Public Zero (Bundle Saved Instantstate) {Super. Contents (Saved Instantstate); SetConte...

How can I verify linking between compiled Java code? -

Generally speaking a group of code (client code) links against any other (API code). Java linking is typically verified between Java and AMP; At the compilation time or between the class Class & amp; Class on runtime However, in the latter case there is verification and when bad references face (i.e. it is lazy). Is there a way to validate the all link between the client code, code code at once, with the API code? Its purpose will be to verify that the client code will work with the given version of the API - even if it has been compiled with another. (Of course, there is a way to decompile and recompile the API, but is there a more direct method?) Forcing the verification of the link is difficult due to nature, for the implementation of language and JVM. I believe the argument for this question is to prevent linkage errors at runtime, and the intention to do so is very valid. However, considering the reasons for a contact error, it is more or less difficult to for...

Right way of accessing elements in an array of matrices defined using typedef in C -

मैंने सी में एक मैट्रिक्स संरचना परिभाषित की typedef डबल मैमैट्रिक्स [30] [30 ] [10]; तो अब मैं उनमें से एक सरणी को परिभाषित करता हूं; मैमैट्रिक्स एए [10]; अब मैंने एक मैट्रिक्स के लिए, तत्व (i, j, k) के लिए उपयोग करने की कोशिश की, इसलिए मैंने इसे एए [5] का उपयोग करने की कोशिश की एए [5] [आई] [जे] [के] = 234.0; यह सही तरीका है? धन्यवाद यदि आप: printf ("% d \ n", & amp; एए [ 1] [0] [0] [0] - और एए [0] [0] [0] [0]); आपको 9000, या मैमैटिक्स में तत्वों की संख्या देखना चाहिए।

c# - why Request.QueryString replace + with empty char in some cases? -

I have a problem that if I pass a string in which + is in a query string And try to read it, it gets a single string, but with the empty letter + by changing For example if i ../ Page.aspx? Data query = sdf1 + sdf , then in the page load, the data by data = request. Is being read. JQuery String ["Data"] will find it as below data = "sdf1 sdf" I resolved any empty letter + .. There is a problem by changing, but is there any such problem which is the reason? And what's the solution with the empty characters + in all cases? Because + url is represented by encoded location "" . If you want to undo Plus Plus in your value, then you have to encrypt the URL: "/ Page.aspx? Data =" + HttpUtility.UrlEncode ("sdf1 + sdf" ) which will generate: / page.aspx? Data = sdf1% 2bsdf Now when you Read requests.cotstrings ["data"] will receive what you expect.

c# - is it better practice to return a complex object or use reference/out parameters? -

I am putting a method that is considered to evaluate the input and if all conditions are found or false Some true test fails, if there is a failure, then I also have some kind of position message available for the caller. The designs I have come up include the returning of bool and using an out (or ref) parameter for the message, an example of a (specially designed) class bool And returning with string properties or even returning an NM or returning signal or a specific error is returning. What is the best way to get all information from the method? Is any of these "good"? Do anybody have other recommendations? I usually try to return a complex object and an out parameter when I have to do But you see the TryParse methods in NET's conversions, and they follow the pattern of returning a value of the converted values ​​and an external parameter return. Therefore, I do not think it is bad to get the parameter out - it really depends on you what you are trying t...

PHP Static Method Using Private Class Functions/Variables -

अगर मैं एक वर्ग में एक सार्वजनिक स्थिर विधि लिखता हूं ... सार्वजनिक स्थिर फ़ंक्शन get_info ($ प्रकार) {स्विच ($ प्रकार) {case'title ': self :: get_title (); टूटना; }} मुझे अपने get_title () फ़ंक्शन को सार्वजनिक के रूप में लिखना होगा ... सार्वजनिक स्थिर कार्य get_title () {return 'title'; } नहीं तो मुझे त्रुटि मिलती है: निजी विधि को कॉल पेज :: प्राप्त_चिटिल () कौन सा मुझे लगता है जैसे फ़ंक्शन get_info () अनिवार्य रूप से बेमानी है I मैं मान्यता उद्देश्यों के लिए अपने वर्ग के अंदर एक निजी विधि से कॉल करने के लिए सक्षम होना चाहता हूं क्या यह असंभव है? PHP> 5.0 btw। ! ###### संपादित करें समाधान (लेकिन सवाल के जवाब नहीं) #########! यदि आप उत्सुक हैं, तो मेरा काम स्थिर कार्य के अंदर मेरा स्थिर फ़ंक्शन वर्ग को इन्स्तांत करना था। इसलिए, वर्ग का नाम पृष्ठ था, मैं ऐसा करूँगा ... सार्वजनिक स्थिर फ़ंक्शन get_info ($ प्रकार) {$ page = new Page (); स्विच ($ प्रकार) {case'title ': $ page- & gt; get_title (); टूटना; }} सार्वजनिक फ़ंक्शन g...

r - Replacing character values with NA in a data frame -

I have a data frame (in random places) a character value ( "foo" ) That I want to replace with NA What is the best way to do this in the entire data frame? this: df [df == "foo"] & Lt; - NA

Linked CSS and jquery.html() -

Whenever I dynamically change the html of an element, no external CSS (excluding inheriting elements from parent elements) Elements From external CSS, I mean that the style tag (without the source property) input directly into the page without the tag. Is there any way to implement them? They should apply. You're probably removing a required element, which is necessary for the styles to apply. If you have posted your code, we can confirm it.

sql - creating a trigger to update orderdata -

I have created a trigger in MS SQL Server 2005 is considered to trigger trigger orderdata. Example: Update Table ID Order 1 1 2 2 3 3 4 4 so that there will be 2 orders for ID4. Table ID Order 1 1 2 2 3 3 4 2 With my trigger, it will automatically create it afterwards. Table ID order 1 1 2 3 3 4 4 2 My table looks distinctly different, but it does not matter too much, my The trigger should look like this. ALTER TRIGGER [dbo] [Testtrigger] running [dbo] After updating [pages], the declaration @ordernr numeric (18, 0) @parentid declares declaration as insert (18, 0) declaration @thisid numeric (18, 0) set @ordernr = (from the selection) Top 1 pageOrder) set @parentid = (top 1 pageParent from selection) set @thisid = (select from top 1 pageId to insert) if exists (select pageOrder from dbo.pages where PageParent = @parentid and pageOrder = @ordernr ) Start the update dbo.pages SET pageOrder = @ ordernr +1 where pageOrder = @ ordernr and PageId! = @thisid and PageP...

Iphone simulator 4.0 home button does not stop xcode debugger -

Can anyone help me? I run my application via Xcode IFile Simulator 4.0, now I want to stop my application, so when I click on my iPhone Simulator Home button it can not stop the debugger I do not know why? Can anyone help me? Is the Exode Debugger still running? I was not seeing any such problem in iPhone OS 3.0 ... Thank you in advance ... The Home button now suspends the app in the background. With iOS 4 you have to kill the process.

How to get a single file from a folder in java? -

The idea is to take a file, but I do not want to list all the files. I have the address of the folder specified, but the name is not. Actually I want findFileInFolder (string folder name) --- this method returns a random file name or created on the old file folder Has anyone ever tried to do this? Added: In the case of the bus I was not clear (I'm doing) really sorry for my English. Please forgive me if I make a motivational or aggressive sound, in fact, this is not my intention.) File is not selected by any person, it is chosen without any request by the machine or showing the file string With filename string fail infaller (string folder name) As I am commenting about the use of RAM and processor because it is a secondary form Process and is not the primary of the project, so if I have to read one thousand files, which will greatly reduce the performance of my project: ( thanks;) Update: The program is running on different computers, so I could simply acces...

security - Cleaning up HTML from textarea -

I have a page with two textures where registered users can fill them with HTML code. Firstly the TinyMCE (hence the HTML has been cleared), but no one else does, because I hope the code is inserted as embed code from other sites (most of the sites which are Maps, such as Google Maps, MapMaris, etc.) Will go. But the problem is that these other sites can provide different tags, not just & lt; Embed & gt; or & lt; Iframe & gt; So I can not cut tags because then I can strip those tags that I did not know other sites. I will retrieve and display HTML as part of some other pages to save HTML in my database in these two textures. Do you have any suggestions for making this setup more secure? Or should I completely reject the free input of HTML in 2 lessons? (Or .. I allow users to maintain a check box, "I accept full responsibility for the behavior of code that I am inserting" ..) Highly appreciated your opinion Thank you The short answer is: Free HT...

JSON PHP Javascript - Simple Working Example -

हाय, मैं निम्नलिखित कोड का उपयोग कर रहा हूं अनुरोध .js var अनुरोध; फ़ंक्शन रनएजैक्स (जेसनस्ट्रिंग) {// फ़ंक्शन रिटर्न "AJAX" ऑब्जेक्ट, वेब ब्राउजर पर निर्भर करता है / / यह देशी जे एस फंक्शन नहीं है! अनुरोध = नया XMLHttpRequest (); Request.open ("GET", "request.php? Json =" + JSONstring, सच है); अनुरोध। चेतावनी ( 'कहा जाता है'); request.send (शून्य); } फ़ंक्शन sendData () {// यदि अनुरोध ऑब्जेक्ट प्राप्त हुआ है तो प्रतिसाद (request.readyState == 4) {// parser.php प्रतिक्रिया var JSONtext = request.responseText; // प्राप्त स्ट्रिंग को JavaScript ऑब्जेक्ट में परिवर्तित करें {// var JSONobject = eval ('(' + JSONtext + ')'); Var JSONobject = JSON.parse (JSONtext); } पकड़ (ई) {var err = "त्रुटि:" + e.description; चेतावनी (गलती); } अलर्ट ('1'); // नोटिस कैसे चर इस्तेमाल किया जाता है {var msg = "त्रुटियों की संख्या:" + JSONobject.errorsNum + "\ n-" + JSONobject.error [0] + "\ n-" +...

sql - How to retrieve the status of Foreign Key constraint? -

I have a SQL query to obtain all constraint name, but it is not sure that the position of how it enable / disable? SELECT OBJECT_NAME (Obijeisiaidiaidi) AS Nemf conference, SCHEMA_NAME (Skima_aidi) AS schema, Obijeianet (Perent_objekt_aidi) AS Teblnam as, Taip_desk S Badhytaprkar, from * sys.objects Any help? OBJECTPROPERTY (OBJECT_ID ( 'FK_foo_bar', 'CnstIsDisabled') oR use the column "is_disabled"

iphone - UIImagePickerController iPad problems -

मेरे पास निम्न कोड है: UIImagePickerController * imagePicker = [[UIImagePickerController alloc] initWithRootViewController : स्वयं]; ImagePicker.delegate = self; Popover = [[UIPopoverController alloc] initWithContentViewController: imagePicker]; [छविकार रिलीज]; [Popover presentPopoverFromRect: CGRectMake (100, 100.0, 0.0, 0.0) inView: self.view अनुमतिएरो डायरेक्शन: UIPopoverArrowDirectionAny एनिमेटेड: हाँ]; लेकिन यह केवल self.view को नष्ट कर देता है और कुछ भी नहीं दिखाता है। जब मैं इनव्यू को सेट करता हूं: [self.view window] से कम से कम पिकर दिखाई देता है लेकिन यह अभी भी self.view हटाता है मुझे क्या करना है कि दृश्य गायब नहीं होता? आप गलत UIImagePickerController को आरंभ कर रहे हैं I इसे बदलने का प्रयास करें [[UIImagePickerController alloc] init]

vb.net - Setting up a 'Timeout' feature in windows forms app -

Someone knows how to create a timeout feature in a Windows app app. App event is run, but I'm thinking of using a timer in some way which says for 10 minutes, and the timer stays, then we're out of the user. The problem I have is how can I reset the timer Cheers Text "> You can use System.Windows.Forms.Timer . , you can drag it from your toolbox to the designer surface . Interval Use the asset window to set the time period (milliseconds) you want the property to, enabled property to be set to false To load set the timer enabled property to true. (The sample in the event handler is written using C # - this Private Zero form1_load (object sender, eventAgps E) {timer1.Enabled = true;} To register on the event Double click on the timer tick event, and close the form on the timer tick Private Zero Timer 1_Tick (object sender, event strings) e) {Close ();}

T4 code generation without Visual Studio 2010? -

Is it possible to run a T4 code PDF without the need for Visual Studio 2010? Actually I have to make an ORM in the house (do not ask if I had an option which I do not). I was planning to use the subsonic as a base, but how to change some things and how they work, though my main question is whether I can run T4 from an external application which I write, so I Can I use features of T4? Or am I doing myself better (which makes me doubt)? Text Transform. For simple scenarios: Here is a way to run a T4 template from your code for templates created in VS 2010: And here's how to run a T4 template with your own code for templates created in VS 2008: SubSonic T4 template outside of Visual Studio There are some issues in running: I will be on T4 instead of rolling my own template engine.

ipad - iPhone SDK: Observe current time of AVAudioPlayer -

Is there any best practice to get an event on every other playback of an aviable player? When you start playback, then one or more of the NSTM Start the example, and you can change the view by looking at the timer (fire).

How to restrict access file from Apache Server? -

If I allow the user to upload the file, then the user files the file after uploading wwww.someplace.com/public_file/ ... .... Therefore, you can access all files. But I would like to make some restrictions on that. For example, I want to reduce download speed for non login users. How can I do that? In addition, if I want to limit the user to receive the file, then he does not have the user's right ... ... for example, if some users at wwww Uploads in some places / secret_place / ... ... Only the user has some rights, can access this place ... ... I How can i Should I also do this web application and Apache server in config? Thank you. For users, you can split it between Apache and your application because I know that most Servers use a database to support authentication; Apache definitely supports several methods of authentication, you should get some useful information here: The point of attention is that if you were working specifically in this application ...

php - Create another dimension to an array housing urls with base url -

Currently I have an array that lists the email address as values ​​in the form of the key and the URL, I create parse_url (unless some better suggestion) and another dimension in the array with the base URL. I currently have this: array ('email@email.com' = & gt; array (0 = & gt; 'http://www.google.co.uk/ Foo / bar ', 1 = & gt;' http://www.reddit.com/r/programming/ ',),' email2@email.com '= & gt; array (0 = & gt;' http: //stackoverflow.com/faq ', 1 = & gt;' http://de.php.net/parse_url '),' email3@email.com '=> Array (0 = & gt;' http: //www.bleepingcomputer.com/forum/ ',),) and that I should have this output: array (' email @ Email.com '= & gt; array (0 = & gt;' http://www.google.co.uk/foo/bar ', array (0 = & gt;' www.google.co.uk ' ) 1 = & gt; 'http: /www.reddit.com/r/programming/', array (0 = & gt; 'www.reddit.com'),), ...

flex3 - How do you integrate Flex 3 with Spring 2.5 -

Spring 2.5 can be used with Flex 3.x, my basic question was confusing "post-text" itemprop = "text"> Yes. We have projects that use Flex 3 with Spring 2.5 and another project that uses Flex 4 and Spring 2.5. The only reason to use the Flex 4 project Spring 3.x is that when we started with the project, there was no shortage of a Maven for it

symbian - Mobile Programming -

I want some tutorials about mobile app programming, I have a Nokia 7610 and a Nokia 6070, I want to know the appropriate. I use tools, and how to use them. I would also like some emulators for different types of mobile phones. You can find tools, SDKs, IDEs, samples

user controls - .NET imagebutton - does it require codebehind? -

I have a simple to log in to a member area on a website. NET user control is created (the site is powered by Umbraco and uses its membership provider). It worked fine until I changed the submit button to an image button on the log-in user control. Now it does not seem to be presenting everything - it reloads it after clicking on the page and does not log the user. At the moment, control is being inserted as a standard .aspx usercontrol, without compiling it in a DLL - which works with standard submit buttons but does not have the image button with it To get an image button, the code behind the code is required, so I have to compile it, is it right? I can probably tell that I am a total noob on .NET, so any advice would be very good. Here I have the code: & Lt; ASP: login id = "login1" run = "server" & gt; & Lt; LayoutTemplate & gt; & Lt; Fieldset & gt; & Lt; Legend & gt; Login details & lt; / Legend & gt; &...

JavaScript and third party cookies -

Say that a site is foo.com that loads JavaScript from the site Bar.com . Now, JavaScript from the site says that bar.com tries to read the cookies using document.cookies . I was using JavaScript under this assumption, you can read all the cookies set in the browser, despite your source. But it has come to know that javascript can access cookies set by the site bar.com only by bar.com and not anyone else. If this is the case, how are the attacks of script injection that steals cookies? but it has been found that javascript from site bar.com is set by bar.com only Can access cookies and not anyone else. This is not true what matters, where & lt; Script & gt; HTML document with element is not a URL of JS file, which is is mentioned in the src attribute. I suspect your problem when you have property document.cookie ( Singular! ) document.cookies )

Username according to ASP.NET Windows auth doesn't match logon name in Active Directory -

To match the new company's policy for logon names, my colleague today changed its user logon name into Active Directory Have given. On your machine, the% username% environment variable now displays the new logon name. Our intranet, which uses Windows authentication (NTLM), is still reporting its old username (via the page. User Identity.Name). I know that ASP.NET can cache user credentials, but we have closed down and then restarted the app pool but still this is a symptom. Anybody advise what's going on? This is due to caching on a web server. WindowsPrincipal has been taken from the cache, the only way to clean the cache is to reboot the web server machine. There are some code changes that you can apply (to use the Windows API), but I would recommend only a quick reboot.

django - How pyamf.amf3.ByteArray save to ImageField? -

I am getting the object 'pyamf.amf3.ByteArray' How can I save it in ImageField? obj - an object in the project, data - array which Meets data ['last image'] - includes a pyamf.amf3.ByteArray and image obj.image - an image field new_name - The name for image (without path) from django.core.files.base import content file obj.image.save (new_name, contentfile (data ['last image' ] Read ()) obj .ave ()

osx - Change the default directory of emacs with 'cocoa emacs' -

As explained in , the default directory in .macs (setq default directory "~ / desktop / mag") is inserted When I do this with emacs on my Mac, it does not work. C-XC-F still shows ~ / not ~ / Desktop / mag (CD "User / Smo / Desktop / Mag") also gives me this error - Error: Any such directory is CDPATH Not found through the environmental variable What has happened to them? "post-text" itemprop = "text"> The default directory visible in the prompt for Cx Cf ('find-file'), which is a buffer-local variable When you first start Emacs, the initial buffer displayed is GNU Emacs buffer. The default directory of the buffer is set to the variable command-line-default-directory. So, try it: (setq command-line-default-directory "~ / desktop / mag")

jquery-ui buttons sometimes slow to render, css alternative? -

I'm using jquery-ui button support looks good, stylish buttons are good only The downside is that It appears that the button is rendered in Javascript, so sometimes there is a break when the page loads and you see that all the buttons change jquery-ui style buttons from the original buttons. Is there any 'button manufacturers' out there that can generate CSS for just one button that I can apply to get the same effect on a single device? I was probably thinking that if I manually styled the button, then the browser will prepare it before the page will be shown to the user anytime, to avoid this strange pause. Thank you Some things - First of all, if you are doing this just to create a static button (Read: Not as a replacement for checkboxes or radio boots ) You can always use javascript-generated HTML, in fact without having to call the .button function. After inspecting the button function next element called, you will see that the HTML has been slightly alte...

What's the best way to extract a tree from a git repository? -

Removing a block from an arbitrary modification is easy with git shows , e.g. : GIT show master: src / hello-world.c> /tmp/hello.c However, I want to know whether git is similar to extracting a tree (directory) and under which everything is continuously? I have written this a small script, so I will add it as a possible answer. It seems that this is something that can be made well in GIT, but I do not know how to find it ... You can use git archive for this. git archive master: src / | Tar -C Destination -x

xml - Service, but no WSDL -

I have to get data from the web service, but they do not publish the WSDL file. My SSIS component will not work without the WSDL. Is it possible to create a WSDL file for someone else's web service? From the prospect perspective, this is theoretically theoretically. On the other hand, it is very difficult to make, and suffers from many errors. First of all, do you have a representative message for the service?

java - wsdlc Ant task ignores constraints -

I'm trying to create web service projects using Eclipse with Oracle Enterprise Pack. When creating web services from the WSDL document using the Wsdlc ant function, all restrictions / barriers to WSDL are completely ignored. Is the POOs forced to use the underlying constraints such as " MINIKACHERS = 1 or ENRUTATION? tomorrow > Unfortunately, I was unable to find the answer here, but in the end I answered I am posting it now because in the future somebody else may be able to help this position. There is no way to add verification to POJO. However, one way to start the schema is to ensure verification that when a web service receives the message it is in accordance with the constraints set by the WSDL, by adding "@SchemaValidation" annotation above the definition of your service class It can do this work for weblogic, but I'm not sure that this is also a standard for other types of application servers.