Posts

Showing posts from February, 2011

how to select a pre-defined value in bootstrap 3 dropdown -

Image
I have the following fiddle, it all looks fine, but the point is that instead of initially selecting 'I' The first option was to put in the selected dropdown. How can I go about doing this? & lt; Div class = "input-group-btn" & gt; & Lt; Button type = "button" class = "BTN BTN-default dropdown-toggle" data-toggle = "dropdown" & gt; Yellow Janis Search & lt; Span class = "carat"> gt; & Lt; / Span & gt; & Lt; / Button & gt; & Lt; Ul class = "pull-down menu pull-right" & gt; & Lt; Li & gt; & Lt; A href = "#" & gt; By clicking & lt; / A & gt; & Lt; / Li & gt; & Lt; Li & gt; & Lt; A href = "#" & gt; Toko & lt; / A & gt; & Lt; / Li & gt; & Lt; / Ul & gt; & Lt; / Div & gt; It looks like what happens when you select a value from the dropdown, it only goes to the link given...

html - Shrink navbar while scrolling down using Bootstrap 3 -

I am using Bootstrap 3 for the development of a website. I need to create a navbar which should be as small as the user's scroll down. Something like this - How can I make it? I'm using a fixed-top example of bootstrap as the starting point - I need to put a logo on the left instead of the text and reduce its size as the user scroll down. ! Thanks in advance. A good example of scrolling is here: $ (Window) .scroll (function () {if ($ (document) .scrollTop ()> 50) {$ ('nav') AddClass ('shrink');} else {$ ('NAV'). Class ('shrink');}});

java - How do I query an fts table in sqlite for one column matching and another NOT matching a particular query? -

I have a suggestion table (FTS4) that was used to provide suggestions for a query in the Android Action Bar Search. goes. I need to query the table for suggestions where a column ( suggest_text_1 ) matches the query text, and the second column ( data_type ) does not match any particular query , Then say 2 . My current selection is text table_suggestions MATCH and I '?' Trying the following logic text to replace for / code> - suggest_text_1: * S1 * and data_type: not 2 . The problem is that, the table is giving me some suggestions, even if the data is there, can I be told to do this query correctly? The SQLite library is not usually compiled in Android, with enhanced query syntax, so that you can see the Something like using suggest_text_1: S1 * data_type: -2 would be in SQL: select from dokid, suggest_text_1 to MyTable WHERE MyTable MATCH 'suggest_text_1:' || ? || '* Data_type: -' || ? FTS only supports prefix queries; You can not...

C: return matrix from a function -

I am trying to run the following code in DEVC ++ v5.5.2 The following error is "Return from Incompatible Notification Type" Another error related to the heading "Return Arrival" title file shows the "Incompatible Type" double complex "when specifying to type" double complex "result in line [0] [J] = circularsoft (AR) ; " Please thank in advance main.c c enter code here # include & lt; stdio.h & gt; #s & Lt include; from conio.h & gt; #to & lt; stdlib.h & gt; #include "complex.h" #include "shiftcheck.h" #define size 6 double complex * circular shaft (double Complex ARE [1] [size]); zero performance (double complex ARR [1] [size]); int main () {int no, i, j; dual complex (* result) [839], * result 1; Double Complex ARR [1] [SIZE] = {2,3,4,1,8,9); Printf ("\ n" How often do you want to make the circular transfer to the array Do not want? \ N); scanf ("% d", & am...

how to sum time in sql server 2008? -

How to sum the time column in SQL Server I want good luck on Monday, Tuesday, Wednesday, On Thursday, Friday and Saturday and updated I Tot_hrs I have the update logic I am unable to sum from Monday to Saturday Create table WEEKLY_ATTN ([SYSID] [int] identification (1, 1) Not empty, [EMPLOYEE_SYSID] [int] tap, [mon_de] [varchar] (10) tap, [tue_day] [varchar] (10) tap, [Wednesday] [varchar] (10) tap, [gurud day] [Varchar] (10) NULL, [Friday] [va Rchar] (10) NULL, [Saturday] [varchar] (10) NULL, [Tot_Hrs] [varchar] (20) NULL); INSERT WEEKLY_ATTN (employee_sysid, mon_day, tue_day, wed_day, thu_day, fri_day, sat_day) Price (41, '11: 01 ',' 11:57 ',' 11:02 ',' 10:19 ',' 09:26 ' ,Zero); Below is the query that I've used select mon_day, tue_day, wed_day, thu_day, fri_Day, sat_day, cast (dateadd (s, isnull) Dated (S, 0, Mon_de), 0) + unknown (dated (0, Tue_day), 0) + isnull (dated (s, 0, wed_day), 0) + isnull (dated, 0, master-day), 0 ...

inheritance - Get enum size from parent interface in java -

I have an interface ParentInterface and there are several enforcers to implement it: ChildEnum1 and ChildEnum2 . I have a method that I pass as the ParentInterface parameter. By which method is passed the ChildEnum , I want to get this size of anonymity How can I do this? The values.length () method works only on enums , but we are going through the caller only in ParentInterface . How can we achieve it? with reflection, Dirty demo): package com.stackoverflow.so21821751; Public Class Test {Interface ParentInterface {void someMethod (); } Stable enum implements ChildEnum1 ParentInterface {FOO, BAR, LOL; @ Override public zero; some method () {// some}} static enum ChildEnum2 ParentInterface {FOO, BAR; @ Override Public Zero Some Method () {// Some}} Public Fixed Zero Main (Last String [] args) {foo (ChildEnum1.BAR); // 3 fu (hair annam 2.fu); // 2} Private Static Zero Foo (Last ParentInterface i) {System.out.println (i.getClass (). GetEnumConstants (). Length...

jquery - JavaScript runtime error: 'console' is undefined in internet explorer 8? -

जावास्क्रिप्ट रनटाइम त्रुटि: 'कंसोल' इंटरनेट एक्सप्लोरर 8 में अनिर्धारित है? लॉगिन फॉर्म Window.onload = function () { // संपादित आगंतुकों टैब var भाई बहन = ($ ("li.pull-right") चुनें। भाई बहन ()); के लिए (var i = 0; i & lt; = siblings.length - 1; i ++) {console.log (भाई बहन [i] .innerText.trim ()। ToLowerCase ()); अगर (भाई बहन [आई] .innerText.trim ()। ToLowerCase () == "आगंतुकों को संपादित करें") {भाई बहन [i] .setAttribute ("वर्ग", "सक्रिय पुल-दायें"); } अन्य {भाई बहन [i] .setAttribute ("वर्ग", "पुल-दायें"); }} & Lt; / script & gt; & Lt; / head & gt; & LT; बॉडी & gt; & Lt; div & gt; & Lt; ul class = "nav nav-tab nav-core nav-heros" & gt; & Lt; li वर्ग = "पुल-दायें" & gt; & lt; a href = "EditVisitor.aspx" & gt; विज़िटर को संपादित करें & lt; / a & gt; & lt; / li & gt; & Lt; li वर्ग = "पुल-दायें...

python - Print Webkit report gives Error -

I am using 64 bit Ubuntu 12.04. When I print the web kit report when I print the wkhtmltopdf package, it shows the following error. Wkhtmltopdf library path is not set Please install the executable on your system (sudo apt-get install) wkhtmltopdf) or download it from here : Set the path in ir.config_parameter in the webkit_path key.minimal version 0.9. 9 Please help me configure the WebKit package Everything else is similar @Adamian Merrell explained.

ios - Audio recording won't work after incoming call -

I am trying to record voice from the microphone and later it runs on the speaker. I use this code to complete [[Avidio session sharing] Set Category: AVAudioSessionCategoryPlayAndRecord Error: Zero]; [[Avidio Session Shared Instance] Override OutputAudio Port: Aviadisonation PortOperide Speaker Error: Zero]; [[Avidio Session Shared Instance] set active: yes error: zero]; This works fine, but if incoming calls are received (when the app is active), after the call is finished and the app resumes, the microphone input is no longer come to know. I tried to handle - (zero) applicationDebackActive: (UIApplication *) application and Reset AVAudio session, but it will not work. Do I have to stop the AVIDOrcorder when the app is inactive, and records are recorded? Am I doing something wrong or IOS bug? I'm running on iOS 7. Thank you You are right that you once the call is received, the aviado recorder And once it's over, start it again. However, you do not do thi...

php - How to change the pagination settings in smarty? -

A clever plugin has an PHP code for applying pages to points. & lt ;? Php function smarty_function_pagination_link_01 ($ parameter, & amp; $ smart) {if (is_array ($ parameters ['values'])!) {Return "not array"; } If (0 == count ($ params ['values'])) {return "empty array"; } If (empty ($ params ['values'] ['current_page'])) {return "invalid request"; } $ Value = $ params ['value']; // Separator Betwinn pagination link $ seprator = empty ($ params ['seperator'])? "& Amp; nbsp; & nbsp;" : $ Params ['Separator']; // Category name for $ extra = empty ($ params ['extra'])? "": $ Params ['extra']; $ Current_page = (int) $ value ['current_page']; If (empty ($ values ​​['first'])! // $ retired [] = "& lt; a $ extra href = '{$ values ​​[' first ']}' & gt; & amp; lt; First & lt; / a & gt; "; ...

c# - Drawing 3D Lines with WPF -

We all know that to attract pure lines in 3D space on View Port 3D, within WPF 4.5 There is no native functionality. And I am aware of the fact that there are some 3D toolkits for WPF but for my masterthesis I have built my own 3D engine. It is almost complete but I would like to be able to attract the wireframe of my object (for example, to show the punching of a circular sphere). My engine can present almost every basic geometric form (cube, spherical, cone, cylinder, pyramid, ..) Do you have any idea how to draw the line? (My only idea is to use very thin cylinders or cubes ... but I do not think it is very efficient because I have to present at least 8 digits (12 triangles) for a line So you need your data color, multisamming, width or whatever information you need, in your engine's pixel shader Pass the required data and attract that line with PS T.

c# - How to read XML using Linq with Nested Descendants -

How to read the elements of nested clan in LINQ My XML file format pre & lt; & Lt; PpProperties & gt; & Lt; Name of the project = "CEESI all 2" date = "2013-11-18T16: 48: 54.9452592 + 01: 00" Revised Date = "2013-11-18T16: 48: 57.2413905 + 01: 00" & gt; & Lt; NuclearSystem & gt; Barium & lt; / NuclearSystem & gt; & Lt; Timeline and gt; & Lt; Clip & gt; & Lt; FilePathFP & gt; FPS \ FP001D \ default-wp000-15Oct2012-105001.vxbin & lt; / FilePathFP & gt; & Lt; / Clips & gt; & Lt; / Time period and gt; & Lt; / Project & gt; & Lt; / PpProperties & gt; & Lt; / SmPpProperties & gt; I am trying to use PpProperties in the form of C # code var SMPpProperties = xmldoc Select Descendants ("PpProperties") New {Project in Xmldoc.Descendants ("Project") New {* How to proceed * var SMPPProperties = xmldoc.Descendants ("project...

python - How can I stop Firefox from hanging after clicking a link? -

itemprop = "text"> Webdriver Python binding v2.39.0 firefox 27.0 (but the issue is also reproduced with Firefox 'latest', Firefox 26.0 and Firefox 27.0) In the code below, the execution hits obj.click () for a link on a certain page, the browser is hanging. If the script is killed with Ctrl + C in Terminal (windows), the browser hangs out if it is left on your device, then the browser will hang indefinitely. I'm not sure that I have permission to post HTML for the problem page but I can be able to communicate it with my team. This very code is used to work completely with the same element which is now causing problems. I was suspicious that there was something to do with upgrading the auto firefox, but downgrading has not solved this problem (please see the section I've tried for more details and things about the things I've tried) Def wait_and_click (obj_id, timeout = global_timeout, locator_attribute = 'id'): print ('wait for...

assembly - Why my code doesn't run? -

I am doing my best to know why this code has not been run. VS Express 2010 announced that "PDB file can not be found or can not open", and "myname.exe has turned on a breakpoint" any help, please! ; This program calculates 5! .386 MODEL Flat. Stack 4096 .Data Factor DeWire? .Code _start: mov eax, 5 mov EBX, 5 sub EBX, 1 mul EBX sub EBX, 1 mul EBX sub EBX, 1 mul EBX sub EBX, 1 mul EBX mov div, eax public _start end There is no end to your code. There is no return statement at the end of your function. There is an instruction for termination assembler, it does not generate any code. Assembler will fill the rest of the code segment with the int3 instructions, in order to instantly provoke someone in case of breakpoint obstruction tries to execute code outside a valid code block. To fix your code, it would be best to create a stack frame around your function.

Server Error in '/' Application in c# -

Image
& lt; system.web & gt; & Lt; customErrors मोड = डिफ़ॉल्ट रूप से "बंद" = रीडायरेक्ट = "~ / सामग्री / error.aspx" & gt; & Lt; / customErrors & gt; & Lt; सत्रस्टेट मोड = "इनप्राक" कुकीज = "उपयोग कुकीज़" समयबाह्य = "20" & gt; & Lt; / sessionState & gt; & LT; /system.web> जोड़ा गया सिस्टम web.config code.i को customErrors mode = "पर" में बदल दिया गया है। फिर भी एक ही त्रुटि। कृपया इन कोड को भी जांचें। कोई मुझे इस त्रुटि को हल करने में मदद कर सकता है। यदि आप त्रुटि पढ़ते हैं, तो यह आपको बताता है कि विशेषता "रिमोटऑनली, ऑन, ऑफ" होने की आवश्यकता है आपको मोड = "बंद" से मोड = "बंद" । को बदलने की आवश्यकता है।

How can I call two controller one afetr another in codeigniter -

We need to load two controllers from one controller class. The source is like this: - Public function index () {/ ** twitter feed to Twitter controller ** / $ this- & gt; Load - & gt; Controller ('twitter', 'twitter_controller'); $ Data ['twitter_feed'] = $ this- & gt; Twitter_controller-> Fatch ALL (); Echo '& lt; Pre & gt; '; Print_r ($ data ['twitter_feed']); Echo & lt; / Pre & gt; '; / ** Loading news controller to get the latest news ** / $ this- & gt; Load-> Controller ('News', 'News Controller'); $ Data ['news'] = $ this- & gt; News_controller-> Get_latest_news (); The Twitter controller is loading, but the news controller is not able to load. Please help !! Thanks Redirect ("Controller_name / function_name", / div> "refresh"); // This code is using PHP's header function, this base_arle + 1 parameter is simple Hope ...

php - Magento: How to filter current category by another category - layered navigation -

I have a Magento (1.7.0.2) installation inside some products. I have two brothers (brands and clothes) in the brand, there are all brands of clothing, and there are many sub categories in the dresses (shoes, pants, etc.) I am using layered navigation. When you open a category (can say "shoes"), I display a list of brands in layered navigaitin (I wrote some custom code for it). Here's the problem: When I brand, I want Magen to have results of filtering products of both categories and matching results. Since Magneta's default functionality is only clicked to display items from the previous category, so I have to change it. Do anyone have any ideas? You need to define the attributes for this and you do not have to type custom code for it. . So it will work as a double structure for you, where you add a real matching feature and shadow range for that match feature.

oop - Java Multiple Inheritance -

In an attempt to understand completely how to solve many heritage problems of Java, I have a classic question that makes me clear should do. Let's say that I have sub class birds and horses in class animal and I have a class Pegasus is a bird and a horse from both bird and horses to pegasus . I think this is the problem of classic diamond animal , bird and horses creating class interfaces and Pegasus from them I was thinking that there is another way to solve this problem in which I can still make things for birds and horses. There was also a way to be able to make animals which would be very good but would not be necessary. You can create interfaces for animal classes (class in biological sense), such as Public Interface Compound and then P> public class horse commissions {} and public class implementation of the Pegasus avialaya, Equity {}> Linking to the plates: To reduce the duplicate code, you can create ...

osx - Objective-C - Finding directory size without iterating contents -

I have to find out the size of a directory (and its sub-directory). I can do this again through the Directory Tree and I can summarize the file sizes. There are many examples on the Internet, but it is somewhat difficult and slow process, especially when looking at the unchanging large directory structures. I notice that Apple's Finder application can show a directory size immediately for a given directory. This means that the operating system keeps this information in real-time. However, I am unable to determine how to use this information. Does anyone know where this information is stored and if it can be obtained from Objective-C application? IIRC finder also repeats in the old days, to quickly do this FSGetCatalogInfo (an old File manager call) I think that there is a new POSIX call for it, these days it is the fastest, lowest level API, especially if you are not interested in all information other than size and really easy Need to speed up the speed on the code to ...

python - API Responses with large result sets -

We have a REST API in which we offer customers multiple APIs to attract analytical reports. It may take 5 to 10 minutes to complete some very big questions and can revert responses from 50 MB to 150 MB range. At the moment, the customer expects to wait for the response. We are not sure whether this is actually the best practice or if such complex / big questions & amp; Reactions should be presented in another way. Note: APIs will be called by automated processes to prepare large reports, so we are not certain that marking on the standard page is efficient or desirable. If you need to process a long-running job, then the client points off , It is always better to process asynchronous process. A customer sends a post request, the server creates a new resource (or can initiate immediate background processing) and returns the representation of HTTP 202 work (eg status, start time, expected end time and so on ) In the content-place header, the function URL can be tracked...

file - Traversing through .gz in perl -

I want to go through the .gz file and read the contents of the file. My folder structure: 1) ABC. GG 1.1) ABC 1.1.1) Sample 1. txt 1.1.2) Sample 2.txt 1.1.3) Test 1.txt I wanted to go through .gz, then read the content and printed it Sample test * .txt file test * .ttt should be ignored. Importantly, I do not want to copy / remove Jazz at a different place. I want to read the file in Perl script: Use strict; Use warnings; My $ filename = 'Sample1.txt'; Open (my $ FH, '& lt ;: encoding (UTF-8)', $ filename) or dead file "$ $ $ could not be opened!"; While (my $ line = The second issue is that you have to decompress it, in memory or in a temporary file You definitely will not be able to read the line through the line. Look for compressed files and tar archives.

c# - System.Net.Http.HttpClient instance throws an exception when setting a comma. Why? -

Image
निम्न सिस्टम.नेट.Http.HttpClient पोर्टेबल कक्षा पुस्तकालय को देखते हुए अपवाद फेंकता है: var httpClient = नया एचटीटीपी क्लाइंट (); HttpClient.DefaultRequestHeaders.Add ("प्राधिकरण", "आहा, बीबीबीबी"); अपवाद है: अमान्य प्रारूप पर System.Net.Http.Headers.HttpHeaders.AddInternal (System.String नाम, IEnumerable 1 मान, System.Net.Http.Headers.HeaderInfo हेडरइन्फो, बूलियन अनदेखीअवैध) [0x0004c] / डेवलपर / मोनो-टच / सोर्स /मोनो / एमसीएस / क्लास / सिस्टम net.Http/System.Net में। Http.Headers / HttpHeaders.cs: 195 पर System.Net.Http.Headers.HttpHeaders.Add (सिस्टम। स्ट्रिंग नाम, IEnumerable 1 मान) [0x00011] में / डेवलपर / मोनोचौच / स्रोत / मोनो / एमसीएस / क्लास / सिस्टम। नेट। एचटीपी / सिस्टम। नेट। एचटीपी। हेडर्स / एचटीटीपी हेडर्स। सीएस: 170 सिस्टम। नेट। एचटीपी। हेडर। एचटीटीपी हैडर। जोड़ें (सिस्टम। स्ट्रिंग का नाम, सिस्टम। स्ट्रिंग मान) [0x00000] इन / डेवलपर /MonoTouch/Source/mono/mcs/class/System.Net.Http/System.Net.Http.Headers/HttpHeaders & lt; ... कट...

Bash: How to do decimal number division? -

इस सवाल का पहले से ही एक उत्तर है: 5 जवाब $ num = 12.53 $ (($ num / 5)) काम नहीं कर रहा है। P> केंट $ num = 12.53 $ echo "scale = 2; $ num / 5" | bc 2.50 kent $ awk -vn = "$ Num" 'BEGIN {printf}% .2f \ n ", n / 5}' 2.51 ध्यान दें कि bc 's scale और printf का प्रारूप अलग-अलग परिणाम दे सकता है

Java, How does add to an arraylist work -

I've been trying to get more acquainted with Java recently I got a question that I did not find an answer online. I'm wondering when Java is an arraylist that adds an element, the added element is an element associated with the variable? For example, in the following code: e obj1 = new E (); E obj2 = new E (); List myList = new arrelisted & lt; E & gt; (); MyList.add (obj1); Obj1 = obj2; After the new assignment for obj1 will the value be present in myList change or not? No, when you add an object to a list , The reference is copied and so when you assign obj1 with the new value, the list will be outdated.

facebook - FB users for QA use -

Our users use the FB user to perform various tasks (such as comments and comments) Is there a way to generate that without our opening many fake FB accounts for our tests, there would be a taboo token for the tasks? You can use the test user endpoint given by Facebook, see the document here: With this you should be able to get what you want.

c - cudaMemcpy not responding when copying from device -

I have written the CUDA code for Monte Carlo simulation. I basically have a number of particles and some operations display. To calculate the density in each of my 3D grids, I have an array (on device) where I specify a cell ID for each particle, it is done through the CUDA. I then want to copy the device memory to host the density and the values ​​to be written in the file. However, when my code is running, cudaMemcpy is not responding and after the statement the code has not been executed. I am worried that I have done something wrong while allocating Array and I will be happy if someone can tell my mistake. The important part of the code here is: size_t sizeInt = dim * numParticles * sizeof (int); ... int * h_cellIndex = NULL; // host err = cudaHostAlloc ((zero **) and h_cellIndex, sizeInt, 0); // int * h_cellIndex = (int *) malloc (sizeInt); & Lt; - Either it did not work either ... int * d_cellIndex = NULL; // device err = cudaMalloc ((zero **) and d_cellIndex, sizeIn...

sitecore - set value in the droplink field -

Image
How to assign values ​​to droplinks via coding? Sitecore.Data.Database master = Sitcom. Configuration.feature Gate database ("master"); Sitecore.Data.Items.Item PriceBookHome = master.GetItem ("/ sitore / content / administration / value books / clerical-us-retail"); String currency = "INR"; String Crisis Source = PricesBook. Field ["currency"]. Source; Sitecore.Data.Items.Item currenyDictSource = master.GetItem (currenySource); Foreign currency (item im currenyDictSource.GetChildren ()) {if (im.Fields ["key"]. Value == currency) {PriceBookHome.Editing.BeginEdit (); PriceBookHome.Fields ["currency"]. SetValue (im.DisplayName, true); PriceBookHome.Editing.EndEdit (); }} I get the following error on the dropline after the entry. "This field contains a value that is not in the selection list" Getting the form of an error Droplink source [as the source provided in the currency path droplink] The id...

javascript - Separation of concerns in angular, when to use a service and/or factory? -

I have recently got to catch with kangaroo and trying to bring my head around the concepts It has been made who has made it. So far everything is secret, but I am going there! Nevertheless, I have created a small part of my web site using the Compagieer (it looked like fit in use because I needed to manipulate Javascript object on the browser). As part of this process, I needed to add an object to my model (on the click of an element) Now I ended up with the code given below: var stpApp = angular.module ('stpApp', []); StpApp.controller ('multiStopController', function ($ scope, $ compilation, $ http) {$ scope.inboundJourney = [['Depart departure': '', 'Destination realport': '', 'Sign out': ' ',' Departure '': 9, 'orbit': 'class'}] $ $ scope.addInboundJourney = function ($$ scope.inboundJourney.push ({'DepartureAirport': '', 'DestinationAirport': '',...

javascript - How could i find the text in a specific TD with a css class where TR is stored as this -

मैं इस कोड को tr $ ('# prod_tbl & gt; & Gt; tr ')। प्रत्येक (फ़ंक्शन () {var x = $ (this);}); अब मुझे क्या चाहिए कि मैं टीडी के साथ विभिन्न वर्ग नामों जैसे कि .price, .name चाहता हूँ कि मैं प्रत्येक टीडी के मूल्य को विभिन्न चर में एक्सेस करना चाहता हूं, जब मैं टी के माध्यम से लूप जैसे $ ('# prod_tbl & gt; tbody & gt; tr') प्रत्येक (फ़ंक्शन () {var x = $ (this); Var की कीमत = $ ("टीडी.प्रिस")। पाठ (); var नाम = $ ("टीडी.नाम")। पाठ ();}); प्रत्येक टी के लिए आपको .find () अपने कार्य को पूरा करने के लिए इस संदर्भ में। ऐसा इसलिए है क्योंकि टीडी s प्रत्येक tr के वंश हैं $ (this) , tr को इंगित करेगा, इसलिए हमें इसका मिलान करने वाले वंश को खोजने के लिए .find (selector) का उपयोग करना होगा कोशिश करो, $ ('# prod_tbl & gt; छोड़ा & gt; tr')। प्रत्येक (फ़ंक्शन () {var x = $ (this); var price = x .find ("td.price")। पाठ (); var नाम = x.find ("td.name")। पाठ ();}); कृपया ...

Spring Security 2 userdetail in one session -

I'm doing a web project, one of the requirements is able to login to 2 different user accounts in one browser. For example, if I have www.myproject.com/member logged in and I open a new tab and I log in them then this time in admin www.myproject.com/admin if I have some of my user functions I try to use www.myproject.com/member/user-detail, I get the access denied response. I understand why spring protection saves 1 user information at a time. Edit: EDIT: EDIT: I was able to log on to many browser tabs I want to be, as long as logged-in users have different roles. The single behavior you see is common for a site that uses a cookie Contains stored security in the cookie in the token. This spring security cookie is due to the domain name and the collection of login paths (like www.myproject.com/login ). To see the cookies of Chrome debugger or firebug application, use it. Most web applications behave like this, for example, not up to Gmail, unless it was before, ...

FastCGI and Nginx - Return HTTP Status -

Behind Nginx I have a custom FastGI application and I am struggling to return NGX to anything except 200 status codes. I have tried the following: Setting up fast_cgi_intercept_errors. "Status: 404 Not Found" "HTTP / 1.1 404 not found" "X-PH-Response-Code: 404" "Status: 404 Not Found;" "HTTP / 1.1 404 not found;" "X-PH-Response-Code: 404;" Any help will be great, I am very stuck. Here is an example of how you can return the 404 status code through FCG and C ++ Are there. #include & lt; Iostream & gt; #include "fcgio.h" using the namespace std; Int main (zero) {streambuf * cin_streambuf = cin.rdbuf (); Streambuff * cout_streambuf = cout.rdbuf (); Streambuff * cerr_streambuf = cerr.rdbuf (); FCGX_Request request; FCGX_Init (); FCGX_InitRequest (and request, 0, 0); While (FCGX_Accept_r (and request) == 0) {fcgi_streambuf cin_fcgi_streambuf (request.in); Fc...

javascript - Changing Raphael arc starting position -

I am trying to draw a percentage of a circle clockwise to use the Raphael javascript library, while the initial position Specifying the Right now I have been able to start it clockwise by clockwise clockwise and using the code below at 6 o'clock position, but I want to start drawing at 4 o'clock position (or I specify the ideal In any case). var zodiac = 75; Var archtype = rafael ("canvas", 500, 500); Archtype.customAttributes.arc = function (xloc, yloc, value, total, R) {var alpha = 360 / total * value, a = (-90 - alpha) * Math.PI / 180, x = xloc - R * Math .cos (a), y = yloc - R * Math.sin (a), path; Console.log ('x -' + x); Console.log ('y -' + y); If (total == value) {path = [["m", xlok, yolok-r], ["a", r, r, 0, 1, 1, xlok-0.01, yolok-r]]; } Other {path = [["m", xlok, yolok + r], ["a", r, r, 0, + (alpha> 180), 0, x, y]]; } Return {path: path}; }; Var my_arc = archtype.path (). Ether ({"stroke...

javascript - How to use getJSON with this code -

I have found this select box which uses JSON data to populate the option. . The data is hard, but I want to load the data using the $ .getJSON () method, but I can not find the right code. I think the suggest.json file has started, but There is some other problem happening. Will someone show me to fix this problem? I found the drop down box Original code: This is my failed attempt: & lt; Script type = "text / javascript" & gt; $ .getJSON ('suggest.json', function (data) select {var $ = $ ('# mySelectID'); $ .eee (data, function (index, o) {var $ option = $ (" Lt; option />").attr("value ", o.CODE) .text (o.box1 +" | "+ o.id); $ select.append ($ option);})}}); JQuery ("# ​​mySelectID") dynamicDropdown ({"delimiter": "|"}} & Lt; / Script & gt; Suggest.JSON: [{"box 1": "Africa", "code": 1, "id": "A"} , "Cod...

java - Sequences not resetting for mock HSQL db and causing constraint violation between JBehave tests -

I am facing indexing problems while writing a BDD test with our API (Spring + Hibernate). We use JBHW as our BDD runner and as an HSQL DB. Actually, I have made the following case to understand this issue. I have two stories: Both stories are included on a table called DummyProdach. We know that each scenario is clear before we clear all the data and reset the schema using the following, "TRUNCATE SCHEMA public RESTART identity and no check COMMIT" and then We reinitialize table data using a predefined SQL script which includes 2 inserts to DUMMYPRODUCT, and the sequence (supposedly) using the drop Sequence DUMMYPRODUCT_SEQ Resets; Start the sequence DUMMYPRODUXSEQ with an increase of 3 out of 10; But I am facing very strange behavior because the sequence is not reset between both the stories and the scenarios, instead they continue on the next story / scenario and then reset in, i.e. . Not being in the next block of scenes, due to the constraint violation ...

What are the common methods for having external companies testing your software? -

We are some of the entrepenours that have developed a cross-browser app and backend administration system for the app. Or in fact, we paid a company to develop it. Now we want this professional to be tested, but we do not want to use the same company for this purpose. Integration test functional testing system test stress testing Performance testing Usability tests Some tests, we think the actual source code is required. For unknown parties, we do not feel "comfortable" to overcome our source code, so what are the common ways of outsourcing software to software? You do not need to provide the source for the actual test you specified. You must provide work environments or provide binaries and instructions on how to deploy them. It seems enough for 1,2 (I do not know what 3 means), 4 and 5. This is too late for usability testing. This UI should have been done during the design phase (how do you want to check it now?) But those tests are not enough Y...

link_to syntax in Rails 4 for nested resources -

I do not really understand how to link any other view in the rail. /products/index.html. To indicate ARB and any other view, the product ID form wants to retrieve a product: subjects / index.html.erb link_to What is the correct syntax for this URL: If you use Rake Routes, it will tell you which routes you have, for this, you will need nested resources. Resources: do product resources: end of topics

how to implement search in custom listview in android? -

I have a list and my list has a list view, my list view contacts list edlistxt with me the list view filter I have searched a lot on Google and found some examinations, but none of my work has worked for me - my custom adapter increases the public class ContactListAdapter ArrayAdapter {Personal end activity Activity; Private Final List & lt; ContactStock & gt; Shares; Private Arrestist & lt; ContactStock & gt; array list; Public contact list adapter (activity activity, list & lt; contactstock & gt; objects) {super (activity, rl.ltv.viewdate_detti, objects); This.activity = Activity; This.stocks = objects; } @ Override Public View getView (int position, seeviewview, ViewGroup parent) {// TODO Auto-Generated Method Viewing Stub Line View = Convertview; ContactStockView sv = Faucet; If (rowView == null) {// A new example of the line layout view layout infographic inflater = activity.getLayoutInflater (); Line view = inflater.inflate (R.layout.listview_dieter...

Do javascript templates save server performance over php templates? -

So I'm trying to create a website that uses almost Simophonie 2, backbone and underscore only on the client Runs. Symfony2 uses symfony2 trigger templates for backend and backbone for frontend, which meet in php classes by the server. Will it be possible to trigger the template to save server performance and instead use JavaScript templates (underscores)? Or does it make any difference because the templates need to be brought from the server anyway? A fixed file from the fetching server will always give you server server better performance than a template and return the results Is going to do The probability of being important is very low, and you have to benchmark to figure out how much difference it makes. Obtaining a stable template file from a server and inserting the data into the template to the server after you can not perform better for dynamically generated data file inject it into it. You have to benchmark it. The performance advantage of using client-side...

sql server - Renaming of Table -

I am using sp_rename to change the table name, my query is below Exec sp_rename 'dop. Lok-daly ',' Temp 'App Spinem' Debo People_Future ',' People the Daily 'App Spinem' Temp ',' Dabo. People_future '. My question is, if I execute the same query in parallel with the different table name, since both queries have been using the word dictionary, there is a possibility that people will use the TEMP address ?, I What should be temporary to avoid? exec sp_rename 'dbo.Address_Daily', 'TEMP' exec sp_rename 'dbo.Addresse_Future', 'Address_Daily' exec sp_rename 'Timp', 'deb.adress_future' Thanks using TEMP if your batches are parallel But you can use TEMP as a suffix on the current table name: exec sp_rename 'dbo.People_Daily', 'dbo.People_Daily_TEMP' Exec sp_rename 'dbo.People_Future', 'People Daily' app spinem 'dbo.PopleTaily_TEMP', ...

xml - Android layout Fix -

Image
मुझे नीचे की छवि लेकिन अब मुझे इस तरह का लेआउट मिल रहा है यह मेरा कोड मुख्य xml फ़ाइल में उपयोग किया जाता है। & lt; RelativeLayout xmlns: एंड्रॉयड = "http://schemas.android.com/apk/res/android" xmlns: उपकरण = "http://schemas.android.com/tools" एंड्रॉयड: layout_width = "match_parent" एंड्रॉयड: layout_height = "match_parent" उपकरण: संदर्भ = "। मुख्य गतिविधि" & gt; & LT; LinearLayout एंड्रॉयड: layout_width = "match_parent" एंड्रॉयड: layout_height = "wrap_content" एंड्रॉयड: layout_alignParentTop = "true" एंड्रॉयड: layout_centerHorizontal = "true" एंड्रॉयड: पृष्ठभूमि = "@ drawable / back_gradient" एंड्रॉयड: अभिविन्यास = "क्षैतिज" & gt; & LT; ImageButton एंड्रॉयड: आईडी = "@ + id / imageButton1" एंड्रॉयड: layout_width = "wrap_content" एंड्रॉयड: layout_height = "wrap_content" एंड्रॉयड: src = "@ drawable / मेनू" ...

c# - Return my object from WCF service. -

I have an application that hosts WCF service and I want to return this class object : Namespace classes [[DataContract] Public class network adapter {[Database] Public string name {get; Set; } [Datamember] get public string id { Set; } [Datamember] public string description {get; Set; } [Database] Public String IPadress {Receive; Set; } [Datamember] Private string gateway ip address; [Datamember] public string speed {get; Set; } [Database] Public String NetworkInterfaceType {get; Set; } [Datamember] public string macAddress {get; Set; } [DataMember] LivePacketDevice LivePacketDevice; [Database] Public PacketDevice PacketDive {Receive livePacketDevice; }} Public Network Adapter (LivePacket Devices Packet Device) {livePacketDevice = packetDevice; } Public override string toasting () {Return details; } Public Static Network Adapters [] getAll () {List & lt; Network adapter & gt; List = new list & lt; NetworkAdapter & gt; (); Agarwal (Network Interface Adapter In N...

c# - What is Xamarin Studio's class HttpWebRequest replacement in Objective C? -

I am pretty new to zaminin studio and I need to use a functionality in my code which i I am writing in, which is from the second code, which was previously written in Xeramin (C #). The exormine code is a byte stream of an image attached to an HttpWebRequest example and posted on a server to obtain a processed image. How can I use the same functionality of code in XMRIA using (stream = (HttpWebRequest) WebRequest.Create (string.Concat (new string [] {common .bas edder, "visualize /", generichalper.sevens encrypt (normal.Token), "/", normal.appappag, (Stream request stream = httpWebRequest.GetRequestStream ()) by using HttpWebRequest.ContentType = "application / x-www-form-urlencoded"; ) {Int num = 2048; int i = 1; int num2 = pBytePhotoImage.Length; while (i & lt; num2) {if (i + num> num2) {num = num2 - i;} RequestStream.Write (pBytePhotoImage , I-1, num); float f progress = (float) i / (float) number 2; if (f; progression; = 1f) {nSA...

construction - Create mesh from point cloud -

I have a set of points that I need to build as a concrete trap to form a triangular face set Delauney's Triangulation and any of it makes sense. Any advice on where to start? Note: the numbers x, y, z are in space. thanks :) There are several options for creating a net from the corner: 1: You can use Poisson Reconstruction It is also applied mashlab which is open source and also in PCL 2: Another option is running on Cubes , You can also get an implementation in PCL

shell - Redirect stderr and stdout in Bash -

I want to redirect both stdout and stderr to a file in one file. How can I do this in Bash? Take a look. Should be: yourcommand> File name (both for stdout and stderr file name).

php - How to print taxonomy field in Drupal views-view-table.tpl -

I try to know how to print a categorized word field in the Drupal 7 scenes-view-table.tpl file I am here. The scenario is that I have a content type called a song, and then there is an assortment terminology called album. I have a watch page that displays all the songs in a table and they have the album word I have added a custom category to album classification so that people can buy the album. I need to print those areas above each table. Hope that makes sense "post-text" itemprop = " Text "> table.tpl ? I understand that you want to print the fields with the word. I suggested that you add a relationship with the view (classification word) and can add that you can use all the word fields inside your view.

mysql - SQL Query - Compare all rows from temp table -

मेरे पास एक टेबल है कमरे और एक अस्थायी तालिका Room_Nums कमरे तालिका के लिए कॉलम: कमरे (ID, room_name, max_Adults, max_Children); - कमरा मूल्यों में INSERT (1, "कक्ष ए", 2,1), (2, "कक्ष बी", 2,5), (3, "कक्ष सी", 3,1); अस्थायी सारणी: अस्थायी तालिका यदि मौजूदा कक्ष_नों; अस्थायी टेबल रूम_न्यूम्स बनाएं (आईडी इंट (1), वयस्क इंट (2), बच्चे इंट (2)); - Room_Nums VALUES (INR1,20), (2,2,5) में INSERT भरें; मैं केवल को कमरे का चयन करना चाहता हूं जिसमें max_adults + max_children Room_Nums से आईडी के साथ Room_Nums में सभी पंक्तियों से छोटा या बराबर ( & lt; = ) P> संपादित करें यह MySQL है। यदि Room_Nums में 2 पंक्तियाँ हैं तो इसका मतलब है कि मैं 2 कमरों से पूछता हूं जो मैच वयस्क + बच्चा ex। का चयन करें r.room_name, rn.Adults, rn.children, rn.ID से कमरे में आर शामिल करें Room_Nums rn ON ( Rn.Adults & lt; = r.max_Adults और rn.children & lt; = r.max_Children) 2 संपादित करें इसके लिए पूछना: 1 कमरा:...

ODS Excel Macro Overwritten SAS -

Here is the code % macro ODS1 (type =, var =, data =) ; ODS listing closed; ODS tags EXXAP file = "H: \ live_bide \ Dispersion1.xml"; Proc format; Value myfmt = '# N / A' Other = [11.2]; Run; ODS Tags. Xxxp option (embedded_titles = "yes" sheet_nem = "and type"); Proc Print Data = & amp; Data (drop = type) node style (header) = [font_style = italic font_weight = bold background = # FF9900]; Var _all_ / style (data) = [background = white]; `Format _numeric_ myfmt .; Format date MONYY .; Cross-sectional breakdown measures for title 1 "& var (and type)"; Heading 2 "dispersion measures D1 = minimum 25th percentile 75 percent for level forecast"; Run; leave; ODS tags.excelexp off; ODS listing; `% MEND ODS1;` `% ODS1 (type = RGDPX, data = dispersion 1_rgdx, var = real total household product); % ODS1 (type = gdpx, data = dispersion1_gdpx, server = domestic product); % ODS1 (Type = BFIIX, Data = Faber 1 BIFIX, VAR = Busin...

wordpress - Why does localhost work but my alias does not? -

मुझे वर्तमान में इस apache2 साइट कॉन्फ़िगरेशन है: & lt; VirtualHost *: 80 & gt; ServerAdmin admin@example.com सर्वरनाम इंजन.कॉम सर्वरअलिअस www.engine.com DocumentRoot /var/www/engine.com/public_html त्रुटि लॉग $ {APACHE_LOG_DIR} /error.log कस्टम लॉग $ {APACHE_LOG_DIR} /access.log संयुक्त & lt; / VirtualHost & gt ; अगर मैं इंजन को टाइप करता हूं तो मुझे खाली पृष्ठ मिलता है। मेरी निर्देशिका सेटअप इस तरह है / var / Www। / इंजन। Com / public_html / wp-content ... स्थानीयहोस्ट ठीक काम करता है और वर्डप्रेस की स्थापना शुरू हो जाती है, लेकिन जैसा कि मैंने कहा इंजन। Com मुझे एक रिक्त पृष्ठ लाता है। आपको जोड़ने की आवश्यकता नहीं है engine.com 127.0.0.1 अपने होस्ट फ़ाइल में?

How to specify colClasses when reading a very big csv file into R using read.table.ffdf? -

I use the read.table.ffdf function, trying to read a very large CCV file around the size of 20g I was having trouble in specifying the colClasses option in "FF" package, but read.csv (). I have to specify the callclass option because some column labels are very long integers in the file, such as with 11 digits, for example, the file has two rows 86246, 205,17,171 9,104116343,8435,2013-03-13,12, oz, 1,2,5 9 86246,205,17, 1719,10800749282,8435,2013-03-13,12, oz, 1,2.5 9 Integer 10800749282 is too large for the "integer" type, and it is not only "numerical" or "character" but above the 104116343 value in the row above is not enough, so r is the default From this column will treat this column as "integer" I tried the following but found an error. Does anyone know the solution to this problem? Highly appreciated! dat Your error indicates that there is no 'character' data type implemented within the FF environme...

list - Please explain (python): example_list[a < b] -

प्रश्न: & lt; या & gt; का उपयोग सूची के [] s में करते हैं? उदाहरण के लिए उदाहरण_सूची [a & lt; बी] मैंने कुछ टर्मिनल के आसपास खेला था लेकिन उसने मुझे कुछ भी समझने में मदद नहीं की: & gt; & gt; & gt; Ex = [1,2,3,4] & gt; & gt; & gt; पूर्व [0 & lt; 5] 2> gt; & gt; पूर्व [0> 5] 1> gt; & gt; & gt; पूर्व [0> 3] 1> gt; & gt; & gt; पूर्व [0> 0] 1> gt; & gt; & gt; पूर्व [0 & lt; 0] 1 & gt; & gt; & gt; पूर्व [1 & lt; 0] 1 & gt; & gt; & gt; पूर्व [1 & lt; 5] 2 & lt; या तो true या गलत लौटाते हैं, और ये पायथन में 1 और 0 के बराबर होते हैं। इसलिए आप या तो पहले या दूसरे आइटम प्राप्त करेंगे & gt; & gt; & gt; सत्य == 1 सच & gt; & gt; & gt; झूठी == 0 सच & gt; & gt; & gt; 'एबी' [ट्रू] 'बी' & gt; & gt; & gt; 'ए' [झूठी] 'ए' सशर्त अभिव्यक्तियां शुरू नहीं...

javascript - Bootstrap tooltip lazy load with delay and show -

I am currently using the following code to start the slown initial version of the bootstrap tooltip. After the first hover, everything works fine in relation to the delay, but it just shows on the initial hover I know that it is $ (this) .tooltip ('show'); is due to the method, but I do not know how to use the delay at the same time and show me the $ (this) .tooltip ('show'); , because once I do not show the elements, I see the tooltip until I exit and do not go back. $ (element) .on ('hover', '.item', function () {matchup = ko.dataFor (this) .outup; if (matchup) {if ($ ( This) .attr ('data-original -' '=' ') {$ (this) .tooltip ({title: matchup.Title, html: true, delay: 1000}); $ (this) .tooltip (' Show ');}}}); Updated E) {matchup = ko.dataFor (this) .McPop; if (matchup) {if ($ (this) .attr ('data-original-title')! = '') {$ (This) .addClass (' Tooltip-init ') .tooltip ({title: matchup.Titl...

java - How to implement a simple website counter for myself? -

Image
I have a website, where I would like to keep a count which is pseudo-private "impersonal" I mean This will be a joint link somewhere in my site. And just use me (diet or exercise-counter). I want to look it like this. 2 web page is a simple calculation of one, and it is stable and simple: " And then I want to create a separate page where I am modifying that count, like: What am I curious about: Would I need some simple database to do this? A simple javascript thing? Maybe I can get sample guestbook code and mod. (But I really want a clean page)? I'm not asking for free code, just how It is to do this. If you only read an integer value and Need to Adit if you only have a text file.

javascript - Timestamp validation with regex. jQuery UI -

मेरा लक्ष्य टाइमस्टैंक्स को मान्य करना है (प्रारूप: mm / dd / yy h: mmt उदाहरण 04/25/2014 11: 39 ए ) जावास्क्रिप्ट और jQuery के साथ एक regex कथन का उपयोग कर UI: / ^ (0 [1-9] | 1 [012]) [- \ /।] (0 [1-9] | [12] [0-9] | 3 [01]) [- \ /।] (19 | 20) \ डी \ डी [] ([1-9 ] | 1 [0-2]) [:] ([0-5] [0-9]) (ए | पी) $ / मेरा रेगेक्स स्टेटमेंट प्रारूपित टाइमस्टैम्प के साथ काम करता है इन दो साइटों पर: हालांकि, जब मैं वैध विकल्प का उपयोग करता हूं विजेट फ़ैक्टरी में regexMatch यह एक वैध मान के रूप में टाइमस्टैम्प को नहीं पहचानता है। यह मेरे विजेट के लिए मेरा ऑब्जेक्ट शाब्दिक है: widgetName: 'field', widgetOptions: {लेबल: 'से', कोड: 'फेलटरव्यू', चौड़ाई: 160, आवश्यक: सत्य, वैध: {regexpMatch: ['/ ^ (0 [1- 9] | 1 [012]) [- \ /।] ( 0 [1-9] | [12] [0-9] | 3 [01]) [- \ /।] (19 | 20) \ डी \ डी [] ([1-9] | 1 [0-2 ]] [:] ([0-5] [0-9]) (ए | पी) $ / ', {field:' _newValue '}]}} एम वाई विजेट सभी अंकों के लिए \ d सिंटैक्स के बारे में शिकायत कर...

java - Google Cloud appcfg.cmd can't deploy because can't find appengine-web.xml -

I'm just trying to deploy the basic Hello World project and following its instructions. I got all the steps, but the last one, step 6, where I got this error: D: \ google-app-engine \ appengine-try-java> appcfg.cmd -A aqueous fire -561 updated target \ appengine- try-Java application to read configuration data ... April 24, 2014 16:27:39 com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml serious exception processing target / appengine -tret- Java \ WEB-INF / appengin e-web Xml com.google.apphosting.utils.config.AppEngineConfigException: D did not know: \ google-appengine \ appengine-try-java \ target \ appengine-try -java \ WEB-INF \ appengin com.google.apphosting E-web.xml (AppEngineWebXmlReader.java:75) com.google.appengine at com.google.apphosting.utils.config.AppEngineWebXmlReader.getInputStre (AppEngineWebXmlReader.java:140) on .utils.config.AppEngineWebXmlReader.readAppEngin eWebXml Tools.admin.Application & lt; Init & gt; (Applicat...

Impresspages language settings in backend -

I can not change the language in German. I did this: translate the CMS core Impress pages When you try to download the necessary language while installing a new language, the complete list of available languages ​​of translation can be found on the Transsex website. These translations are done by our community. You can also help and add some translations. If the default translation in your language is missing or you do not like the default, then you can add your own translations. Make a JSON file in the file / translation / override directory with just necessary translations. The JSON file uses the same syntax as mentioned in the above plugin and theme translation cases. Use Ip-admin-fr.json for admin page translation, and for other web site texts, IP-fr.json (here is fr two-letter language code). For plugin translation, use your plugin name. - See more: Language in the backend is already English. What to do? Download the German translation and file it / translation / ro...