Posts

Showing posts from July, 2011

rsync - How to exclude wildcard directory but include wildcard files using rdiff-backup? -

I'm using really awesome simple powerful backup tool though I'm fighting with Wild Card Globe Pattern. The structure is: / data / aaa / cache / data / bbb / cache / data / ccc / cache etc .... each cache directory The original files and cache files in the original files are named only 1.jpg , 2.png , 3.gif , and so on. is. The cache file contains a string connected to some basic file name. So I want to backup all / data / * / cache directories, but only include the original files, not the cache files. I am using this command: rdiff-backup --exclude ** / cache --include ** / cache / + ([0-9]). + ([Az]) / data / backup but rdiff-backup returns this and I'm lost: initial backup should be interrupted There are ... Fatal error: Final selection expression: The globe in the command line includes: ** / cache / + ([0- 9]). ([A-z]) Specifies that files must be included. By default all files are included, so the expression is meaningless because it's proba...

java - JSR 107 - Caching (JCache) vs CPU caching -

I have read about JSR 107 caching (jachet). I am confused: everybody who knows, every CPU manages its caching memory (with no help from the OS). So, why do we need a Java caching handler? Thanks There is a difference between CPU caching and memory caching. This will cache things in the zacate memory, so you do not have to get it from expensive resources on disk or network. Therefore, the cache is created in the CPU so that they can avoid going to memory. The CPU typically has three level caches and 8 MB around the store. CPU caching does not have to worry about anything because it has been taken care of for you. If some CPU is not in the cache, then it has to be taken out of memory. It is like avoiding caching in the memory in memory or avoiding slow resources. As I mentioned earlier, the mechanisms have control over the programs so if you want to constantly ask your DB for some object, then you It can store memory and return to the same object. This has left a littl...

terminal - How to show long git output in separate buffer with less? -

When I open less , then it is in a different buffer (maybe Is there another word for this?): The scroll bar of my terminal disappears and I can scroll with the mouse wheel. , it uses the same buffer as my session, the scroll bars of the terminal remain, scrolling with the mouse wheel scrolls the session and scrolling back and forth (with the keyboard) that's all It leaves something which is ever seen in the terminal. The last thing can be easily displayed by shooting from Jammu and Kashmir, while scrolling the terminal buffer, the first row will be repeated several times. Other devices that use less work, e.g., long output is shown from psql in a different buffer less ? says: core.pager GIT will use to output the page. GIT_PAGER can be overridden with environment variables Note that git sets the FRSX less environment variable if it pager runs, then it is not set. Important part is x lower variable consulting less' man page: -X or --no-init Dis...

How to use the Object Detection Bounding Box in a decision condition to turn on the LED on Raspberry Pi using C++ OpenCV? -

I am using OpenCV 2.4.8 to create an application that will detect guns. The application will be posted on Raspberry P. An LED / buzzer is also connected to Raspberry P. If the gun is detected, then the LED / buzzer should be turned on according to certain conditions. I have attached the relevant code. The problem is how to tell the code whether the gun is detected or not? I mean, the traced gun has been shown by a bounding box. Now, how to use that bounding box in IF-condition? I have commented on the desired lines in the code, like what I really want to do, can someone guide me how to do it? Any help is highly appreciated! Thank you. This is my code snippet: for (;;) {cap.retrieve (frame); Caps & gt; & Gt; Frame; Std :: vector & lt; Rect & gt; Guns; Mat frame_grey; CvtColor (frame, frame_grey, COLOR_BGR2GRAY); Equalize (frame_grey, frame_grey); // Address Guns gun_cascade.detectMultiScale (frame_gray, guns, 1.1, 2, 0 | CASCADE_SCALE_IMAGE, size (30, 30)); // Se...

ns2 code is not running giving some error can't figure out the error -

This is my code for SFQ.tcl. This code was going on completely when I worked on a college computer , When I'm trying to run it on my computer, I am giving some error. Please tell me if someone can tell me where the error is in the installation of NS2 as when I type NS, then I'll call % , but when I try to give errors to the program # simulation time set Val 60.0 (stop); # Prepare new simulator ns [new simulator] set set tracefile [open out.tr w] $ ns detect all $ tracefile namfile set [open out.Nnam w] $ ns namtrace- all $ namfile #create 6 nodes Set N0 [$ n2 [$ ns node ns node] n1 [set ns node set] set] set n3 [ns node] set n4 [ns node] set n5 [ns node] #create link between nodes specific bandwidth With, type the delay, queue & amp; Line size $ ns duplex-link $ n0 $ n2 10.0Mb 10ms SFQ $ ns queue limit $ n0 $ n2 50 $ ns duplex-link $ n1 $ n2 10.0Mb 10ms sfq $ ns queue limit $ n1 $ n2 50 $ NS Duplex Link $ n3 $ n4 10.0Mb 10ms SFQ $ NS Queue-Limit $ n3 $ n4 $ 50 NS Du...

css - Google Maps infobox close button -

I have a problem in my info box on Google Maps. I stole it as though I wanted to, but remove the close button Was given: / ... Does anyone know how to solve this problem? My code: & lt ;! DOCTYPE html & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; Script type = "text / javascript" src = "http://maps.google.com/maps/api/js?sensor=false" & gt; & Lt; / Script & gt; & Lt; Script type = "text / javascript" src = "http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobox/src/infobox.js" & gt; & Lt; / Script & gt; & Lt; Script type = "text / javascript" & gt; Function initialize () {var loc, map, marker, infobox; Loc = new google.maps.LatLng (-33.890542, 151.274856); Map = new google.maps.Map (document.getElementById ("map"), {zoom: 12, center: local, mappeople: google.maps.MapTypeId.ROADMAP}); Marker = new google.maps.marker ({map: map, position: loc...

ios - OS X server for launching Unit Test remotly -

हमारे पास रिमोट ओएसएक्स सर्वर जैसे मैकिन क्लाउड, मैकैटेडियम, वीएमओएसएक्स, एक्सक्लुड, एक्सकोडक्लबल P> मैं किवी का उपयोग करना चाहता हूं अगर कोई सुझाव दे सकता है कि मैं एपीरीसीएट होगा मैकिनक्लाउड की कोशिश करें, आपको आवश्यकता हो सकती है किवी चलाने के लिए उनका समर्पित सर्वर।

Match text via Regex that is within an HTML tag -

Through a Regex, I'm trying to match the word one , only When he & lt; P & gt; tag. & lt; P & gt; Zero One Two Three & lt; / P & gt; Zero one two & lt; P & gt; Zero A & lt; B & gt; Two & lt; / B & gt; & Lt; / P & gt; & Lt; P & gt; Three & lt; / P & gt; & lt; P & gt; Two & lt; / P & gt; Three should be a match above # 1 and # 3. It seems that I need a letterhead which ensures that a closing tag comes first without an opening and tag which does the opposite). But there is nothing to come up with the correct expression. Any idea is appreciated. You can enter the string one which is & lt; P & gt; is inside the tag. \ bone \ b (? = (?!? & Lt; \ /? P & gt;).) * )

winforms - C# dynamically delete checkboxes -

I am trying to delete a check box from a group box by pressing a button. After this I want to put the remaining checkboxes in order. Private Zero Button 2_Click (Object Sender, EventArgs e) {for (Ii = 0; i & lt; =) Number_ch; i ++) {foreach (control C. control in group box 2.) {if (c.getetpe (.name == "checkbox") {if (((checkbox) c). == true} {groupBox2 .Controls.Remove (C); Number_ch--; }}}}} This works fine but how do I keep the rest in sequence? You should not delete the control, visible = false !

sql server - Error on installing Ssrs data connector -

Image
I am installing SRS Data Connector for MS Dynamics CRM, but there was an error in the system check "Any such The object is not on the server "I have tried to googling it, but no avail. Update: Added some details I'm running 2vm for CRM Both Server is running on Windows 2008 R2 SQL Server is MSSQL 2008 The permission may be a problem, make sure NTAUTORITY \ NETWORK SERVICE to MSCRM_CONFIG Access is allowed. After adjusting the access problem, you may have to reset the IIS on the CRM machine.

php - $_GET not working with & in the URL -

I am working on a Wix widget. In my widget with an IFrame, this URL was generated by Wix: I used the $ _GET from the URL to illustrate and compId values Tried to retrieve but no luck. echo & lt; Pre & gt; '; Print_r ($ _ gET); Echo & lt; / Pre & gt; '; gives me array ([cache culler] => 123456 [ampI; compId] => hackex [and device type ] => Desktop [amp; example] => xxxxxxxxxxxxxx [amp; locale] => n [amp] see] => editor [and width] => 50) Any ideas $ _ GET [amp; Edit my problem about recovering these values ​​without using compId] and $ _GET [and user] To solve, I am using $ compId = isset ($ _GET ['compId'])? $ _GET ['compId']: $ _GET ['comp ID']; -text "itemprop =" text "(& Amp; $ _ GET) {$ _GET [str_replace ('amp;', '', $ key)] = $ _GET [$ key]; Set up ($ _ GET [$ key]);}); Then you can use the keys without the amp prefix.

qt - QGraphicsItemGroup List -

मेरे पास कई QGraphicsItemGroup मेरे QGraphicsScene में खींचा गया है। मैं चयनित QGraphicsItemGroup की सूची प्राप्त करना चाहता हूं। मैं सेटड्रागमोडा (QGraphicsView :: RubberBandDrag) का उपयोग कर रहा हूं; चयनित आइटम्स () फ़ंक्शन चयनित QGraphicsItem की एक सूची देता है। क्या समूहों के लिए ऐसा करने का कोई विकल्प है? संपादित करें मैंने QGraphicsItemGroup की एक सूची बनाई है: QList & lt; QGraphicsItemGroup * & gt; selectionList; मुझे इस सूची में चयनित आइटम (समूह) प्राप्त करना है। मैं कैसे QList टाइप करें चयन सूची प्राप्त करने के लिए यदि आप QGraphicsItem :: ItemIsSelectable , इसमें कहा गया है: - आइटम चयन का समर्थन करता है इस सुविधा को सक्षम करने से, आइटम के लिए चयन टॉगल करने के लिए SELECTED () सेट सक्षम हो जाएगा यह आइटम को QGraphicsScene :: setSelectionArea () को किसी आइटम पर क्लिक करके, या QGraphicsView में रबर बैंड चयन का उपयोग करके स्वचालित रूप से चुना जाना चाहिए। चूंकि QGraphicsItemGroup QGraphicsItem से लिया गया है, मुझे संदेह...

symfony - Number of sessions in Symfony2 -

I am using a simphone 2. The session login is when the user login is successful. How to get an active session count? Do I have to write any code to get this information? There is no way to do this in symfony2. You have to create custom logic to do this.

c# - How to Configure owin/Katana to listen on all host ip addresses -

How to configure an OWin Web server to be accessible from other hosts All examples for local instances are configured Do not know what the URL is (IP address / hostname) code: class program {static string url = "http: / / / Localhost: 9080 "; Fixed Zero main (string [] args) {(WebApp.start> (url)) {Console.WriteLine ("server is running {0}", url); Console.ReadLine (); }}}} = "post-text" itemprop = "text"> You have your URL '*': static string url = "http : // *: 9080 "; This will be less restrictive than the local host.

java - Spring : How to manage datasources created with BeanFactoryPostProcessor, at runtime? -

I am working on a project using Spring Data JPA. I have been able to create dynamic databasers with BeanFactoryPostProcessor and switch to the desired one when I log in using Structuring Data . Now, let me have a map of dynamic data sources with BeanFactoryPostProcessor Keep the recently created data source in the map springContext-jpa.xml & Lt ;? Xml version = "1.0" encoding = "UTF-8" & gt; & Lt; Bem xmlns = "http://www.springframework.org/schema/beans" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance" xmlns: aop = "http: // www. Springframework.org/schema/aop "xmlns: reference =" http://www.springframework.org/schema/context "xmlns: p =" http://www.springframework.org/schema/p "xmlns: Tx = "Http://www.springframework.org/schema/tx" xmlns: jpa = "http://www.springframework.org/schema/data/jpa" ............ & gt; ; & Lt ;! - ... ... spring dat...

How to loop through a list in R -

I have a list that says: dataset $ mixed_bag & lt; - ("USA", "Red", "100"), "C" ("India"), "Hello" , "Blue", "76")) List and new variables based on the list list. A pseudo code will look something like this. the foreach line in the dataset $ mixed_bag {if (sapply (DataSet $ ​​mixed_bag, length) == 3) {dataSet $ ​​country & lt; - dataset $ mixed_bag [[line]] [1]; dataset $ color Please suggest how I R something like this? dataList = list ("Hello" C ("USA" , "Red", "100"), c ("India", "blue", "76")) (in i data list) {print (i)} Returns: [1] "Hello" [1] "USA" "Red" "100" [1] "India" "Blue" "76" or: for (in data list) {for (j) i {print (j)}} returns [ 1] "Hello" [1] "USA" [1] "red" [1] "100" [1...

prolog - Sum from backtrackable predicates or facts -

I am trying to add different values ​​at once, suppose I have this: Facts (fruits, apples, 10) facts (fruits, pears, 20) facts (vegetable, tomatoes, 15) Now, my The problem is that if I want to add weight to all fruits, what have I done so far: printwhite (types): - facts (type, _, r), (type = 'fruit '-> right; wrong), * Here I want to weigh all the fruits Got to add, type = Fruit * No idea about anyone how to solve it? See the documentation for your ProLal implementation for built-in bill bagof / 3 and A more or less standard library means that a list (available in SWI-Prolog, is available as sumlist / 2 ): ? - bagf (w, name ^ facts (fruit, name, w), ws), index (ws, yoga). Ws = [10, 20], yoga = 30.? - bagf (w, name ^ facts (meat, name, w), ws), index (ws, bm). false. The second query fails, because there is no meat product in your database, you can either leave it (you may want to know that there are no specific types of products ) Or use findal...

Wordpress blog not showing on blog page -

I have specified a page in settings to be a part of my site, where my post should appear. When I click on "blog" it only shows me anything which I have recently added to my homepage for some reason. If I click on the "Recent Posts" link, under any page, I'm taken to the blog page which I want but does not take me to that blog page when I click the menu Click the "Blog" link at the top of your page in the strip. I have already removed the blog page and have started setting up a new blog page, where my post should appear but that does not work. I am using the theme "Wideley", which I have downloaded. It appears that your "home" menu In and the "blog" are two separate pages on the left widget bar, you need to link them both to the same page.

How to create a custom JIRA Agile report? -

Is it possible to create custom reports like Sprint or Epic report under the Reports tab in the strange? If so, how can I get it? Is there any tutorial for this? I am experimenting with the JIRA 6.1.7 edition JIRA AGI Plugin . You have several options: , one Free-form reporting plugin (or both of which support jizy agile) Plugin for specific reports (Search) For complete optimization, you can use HTML and Java ()

jdbc - sql cannot operate correctly in Redshift -

I want to run as SQL: as the temporary table select Select * redshift_table from where date & gt; # {Date}; I can run this SQL in the command line in redshift, but if I run it in my program, it does not work correctly. When I do create a temporary table , the create table works correctly. I am using mybatis as a mapper and driver: org.postgresql.Driver org.postgresql: postgresql: 9.3 -1102-jdbc41 What's wrong? I assume that #date is a real date in your actual query. After saying this, there is no reason because this order does not work, according to the syntax listed here, Have you tried posting it on the ADS Redshift Forum, Generally they are quite liable. If you find anything, please update this thread, this is a very interesting issue, thanks!

Changing raspberry pi bluetooth device name? -

I'm trying to change some of the Bluetooth name of a Raspberry Pi and (an IP address) so when I scan Do this and my pair of Android device will see this IP as this device name. It was once, but then "Raspberry -0" As goes back to appear I've tried both hciconfig set name command, and / etc / bluetooth / main. Inside the conf also changed the name of the device but still sees all my device "Raspberry-0" This is driving me crazy, so if someone knows what the problem is, please help! If you want to change the name of the Bluetooth device permanently, you must / etc / machine-info namely to create a file which must contain the following ingredients: PRETTY_HOSTNAME = device-name Continue then restart after service "Bluetooth"

c++ - Get property returns empty variable when try to get Target Link Libraries information -

I have some debug info in the seamkey, to see if I have any necessary information to compile a project Not raised. This code works in the code: Include # directory GET_PROPERTY (dirs DIRECTORY $ {CMAKE_CURRENT_SOURCE_DIR} property INCLUDE_DIRECTORIES) foreach (dir $ {dirs}) Message (status "* Include directory: '$ {Dir}' ") ENDFOREACH () But when I try to check all the libraries connected to the current project, I get an empty variable: # linking foreach (libtarget $ {libtargets}) Message (Status "* Target Link Library: '$ {libtarget}'") ENDFOREACH (: GET_PROPERTY ($ libsLTD $ {CMAKE_CURRENT_SOURCE_DIR} Leaf LINK_LIBRARIES) against message ("$ {libtargets} Libs") It looks properly, but I do not know which value is available to read. I print the information after creating ADD_LIBRARY / ADD_EXECUTABLE Is LINK_LIBRARIES a wrong value for GET_PROPERTY? How do I get information? After the directories LINK_LIBRARIES are n...

android - Sony smartwatch 2 check and change back light status programatically -

I'm working on Android App Extensions for Sony smartwatch 2. I have some listings and gallery views for it now I'm able to open the gallery view on list item clicks. I am using ActiveLowPower when the backlight is dimmed and the user clicks on any inventory view object, then it should first change the blacklight to dull, and if the backlight is bright then it should call the gallery view. How can I check and change the Smart Watch Backlist status? I would recommend using SCREEN_STATE_AUTO for low power mode to complete it. If you set it to Auto, then backlit will automatically come when the user will touch the edge of the clock. Otherwise, you can manually control backlight status through SCREEN_STATE_ON or SCREEN_STATE_OFF. To find out if there is a change in active low power mode state, you can check ControlExtension.onActiveLowPowerModeChange () callback. For more information, see the Active Low Power Mode section:

database - How to perform cascade deleting on foreign key using ormlite in android -

I am using ormlite in Android and have successfully created tables and can complete various tasks using DAO I am But I'm stuck in the removal of the main key and removing the primary key if the primary key has been removed from the main table. I have two tables named Parents and Children, parents have more than one child, so I added the child with the foreign key. Code: Table of Parents: @DatabaseField (id = true) Private Integer id; @ferngencollectionfield (Curious = False) Private Foreign Selection & lt; Child & gt; ChildCollection; Private parents: @ databasesfield (foreign = true, foreign automobile = true, cannabul = false, index = true, columnDefinition = "Integier reference parent (ID) on delimited cad") parent of; Now if I am removing parent line for a specific ID then it is not removing children from the child's table. Delete Public Zero Id (Integer ID) {try {dao Please guide me, where I am doing wrong I tried and Google has...

javascript - How to check for a certain text value with jQuery.validate() -

I use the jQuery.validate () plugin to validate the forms of my website I am here. What am I going to do now, when a text field contains a certain string, an error is thrown. For example, suppose that the string matching is "Penguin". If the user enters the "I like penguins", then there should be an error, although the user can enter the penguin in a word without that word, it should be accepted. Is this a valid way to validate? I can not understand it ... Thank you! check jQuery.validator.addMethod ("title penguin" , Function (value, element) {value = $ .trim (value.toLowerCase) ()); If (this.optional (element)) / ^ ((?? Penguin).) *************************************************************************************** **********************************);)

multithreading - boost shared_mutex destructor -

I have a multithreaded app that often needs to read some data, and sometimes that data is updated Using the upgrade_lock, I have problems using unique_lock and problems. I have an example of my problems: zero unlock () {test.stream = 0; Test.mtx.unlock (); } Zero lock_mtx (int i) {boost :: unique_lock & lt; Boost :: shared_mutex & gt; (Test.mtx) lock; Test.stream = i; Promote: this_thread :: sleep_for (boost :: chrono :: milliseconds (10000)); Unlock (); Promote: this_thread :: sleep_for (boost :: chrono :: milliseconds (1000)); } When I destroy lock , then the Mute X is already unlocked with this thread, and sometimes it's another thread Is locked from, but the district makes it free again. After the destruction of the lock (in the first thread) the third thread takes Mute X and I have two authors in a moment: Zero lock MMTX (int i) (boost :: upgrade_lock & lt; Boost :: shared_mutex> lock (test.mtx); read_from_locked (); to promote: this_thread :: slee...

oracle - PL/SQL - cannot access rows from a non-nested table item -

I am trying to get all the column names of my_table , and make it For example, my_table "year" , "month" , my_fn > "Day" . Get this column name using the all_tab_cols table, and store it in the tmp collection using the For-loop, I use my_fn Make these column names "month, year, day" Currently, I'm getting the following error. Error log - this is what I am getting as an error SQL error: ORA-2295: non -Nested table item can not reach rows from 22905. 00000 - "Can not access rows from non-nested table items" * Reason: Attempt to access rows of items whose type is not known at parse time or * Works of nested table type: Item nested table type Use CAST to enter SQL code - this is my code. Type or replace the cola_re as the table of varchar2 (1000); Change / create or change function I_FN (in input VARCHAR2, input 2 in VARCHAR2, input 3 in VARCHAR2) back varchar2 AS tmp col_array; Texty varchar2 (1000...

if statement - How to test in bash one or two conditions -

I have to check that there is nothing else but a variable: a = "6"; If ["$ a"! = "6"] || ["$ A"! = "4"]; Then echo "OK"; Returns: OK I just do not get it ...? !! try if ["$ a"! = "6" -o "$ a"! = "4"] ... But it is not understood that this condition is always true ($ 4 can not be 4 and 6 at the same time). You might want to: instead of and if ["$ a"! = "6" -a "$ a"! = "4"] ...

javascript - Why i cant install "express"? -

पहले मैंने इंस्टॉल किया: एलडीएस-मैकबुक-प्रो: ~ ldnwty $ node - संस्करण v0.10.31 एलडीएस-मैकबुक-प्रो: ~ ldnwty $ npm --version 1.4.23 lds-MacBook-Pro: ~ ldnwty $ एक्सप्रेस - संस्करण 4.8.0 तब जब मैं मेरी परियोजना में एक्सप्रेस स्थापित करना चाहते हैं: एलडीएस-मैकबुक-प्रो: संपर्क ldnwty $ npm इंस्टॉल एक्सप्रेस एनएमपी वार्न पैकेज.जसन नोड @0.0.0 कोई विवरण नहीं npm वार्न पैकेज.जसन नोड @ 0.0.0 कोई रिपोजिटरी फ़ील्ड नहीं। Express@4.9.6 ../../node_modules/express?a ???? ???? मर्ज- descriptors@0.0.2 एक "????" ???? Utils-merge@1.0.0 एक ???? ???? ???? ताज़ा @ 0.2.2 साढ़े कुकी @0.1.2 एक '????' Escape-html@1.0.1 एक "????" ???? रेंज -परर्स @ 1 .0.2 एक '????' ???? कुकी- सिग्नेचर @ 1 .0.5 एक "????" ???? अंतिम हेंडलर 0 0 0 0 0 0 0 Media -typer@0.3.0 एक "????" ???? Vary@1.0.0 एक ???? ???? ???? ???? Methods@1.1.0 एक "????" ???? Parseurl@1.3.0 एक "????" ???? सर्विस -स्टीटिक @ 1 6 .4 एउटा ???? पथ- to-regexp@0.1.3 एक "?...

wxpython RichTextCtrl. How to set a background color to a text selection -

For example, it is bold Weight: rtc.ApplyBoldToSelection () I am trying to highlight feature highlights in an editor. to There does not appear to be a convient way it is, but looking wxPython demo RichTextCtrl From I came with the following: attr = wx.TextAttr () attr.SetFlags (Wx.TEXT_ATTR_TEXT_COLOUR) r = rtc.GetSelectionRange () attr.SetFlags (wx.TEXT_ATTR_TEXT_COLOUR) attr.SetBackgroundColour (color) rtc.SetStyle ( R, attr) You probably want to put it in a method and you can use it again.

asp.net - Download a file from a WebForm using C# -

I need to download a file from a website (not written by me) I have a valid Username / password, and I can do it manually But I want to make it in an automated process (C #) to be downloaded from time to time. Manually need to login to me, browse to the download page, select some combo box, and then click "Download". This link does a postback and returns the requested file. I think the webclient me Download file should be used, but I can not understand how to pass all the required data and request postback properly. / P> Is this another website API? Otherwise, all you need to do is submit a web request, all the details in the description format, then read the feedback, then automatically fill the second form for "Check some combo box", and then finally file Read that response. Alternatively, there is a browser emulation software, such as Selenium, which is used for website testing. You can install a test / script over there, which will do all of t...

html - Adding single image after a specific list item -

This is probably a bit of a silly question but to achieve some CSS style around me I have an image targeting specific I want to add items. This will add the image after all the li items. . MenuuStyling li: after {content: url ('../img/arrowActive.png'); } What would be the best way to target a Lee item? use nth-child selector, like this: . MenuuStyling li: nth-child (2): after {content: url ('.. /img/arrowActive.png'); } Where the image will be in the second and . See more on nth-child See a snippet below . MenuuStyling li: nth-child (2): after {content: "This hair list is after item 2"; Color: green} and lt; Ul class = "menu styley" & gt; & Lt; Li & gt; Item 1 & lt; / Li & gt; & Lt; Li & gt; Item 2 & lt; / Li & gt; & Lt; Li & gt; Item 3 & lt; / Li & gt; & Lt; Li & gt; Item 4 & lt; / Li & gt; & Lt; / Ul & gt;

javascript - How to store number of object element of array in another array? -

There have been some object elements try to collect from one array to another, so you can say that I have objects I> P> var array = [{name: 'fictitious'}, {name: 'joseph'}, {name: 'salim'}, {name: 'tony'}]; I want to store another array to the first two objects in the array do so var SubArray = [[name: 'Fadi' } {Name: 'Joseph'}]; Thanks in advance for any help. You can use the method for this: var SubArray = Array.slice (0,2); Please note that for the variable that JS global item is reserved for, you have to use a different name. Your code should be, for example: var MyArray = [{name: 'Fadi'}, {name: 'Joseph'}, {name: 'Salim'}, {name: Tony '}]; Var Sabarere = Myere Slices (0,2);

clone docker images from local server? -

I was thinking that there was a way to clone images from local servers. The server is running Containers will be hosted behind a bandwidth constrained connection. There was a way to drag the containers provided for one server and then drag it from the initial local server to update the containers on the rest of the servers. - Text "itemprop =" text "> You can drag those images you want, give Hem a new tag, and put it in your own registry. For example, we say that You set up the official registry image and put it at myregistry.internal.mycompany.com Now, if you wanted to provide a CentOS image for all your servers, but did not want to draw everyone from the official repo (charging bandwiches) , Then you have a centos (We say that Santos: the latest - drag the Docker Centy) and then give that image a new tag like this: Docar Tags Census: latest myregistry.internal.mycompany. Com / centos: latest Now you can pull 'myregistry.internal.mycompany.com/centos...

scala - How to verify a method is called N times exactly in specs2? -

In specs2, I can confirm the time of invocation of a method: There was a (user) .getName there were two (user). Gate name there were three (user). GetName But how to check n times? Something looks like: There were times (n, user) .getName Unfortunately there is no such API If you see the implementation of specs2 bindings for duplication, you will get something like Diff A [T & LT: AIFF] (Fake: T) (Vertical Aoder: Option [inorder] = Inorder ()): T = Czech (Fake, Org. Mokito, Mokitō. Times (1)) (Aodder) So I think that Only define your own bar method by copying that one: def times [t: lt;: any reef] (n: IT , Fake: T) (Vertical AoOder: Option [Inorder] = Inorder ()): T = Check (Fake, Org. Mokito, Mokitō. Times (N)) (An order) Or simply use the mapit: Val mocker = new MockitoMocker {} Verify (user, org.mockito.Mockito.times (42)). GetName

javascript - Open link on any page click -

How to open a particular link (for example, www.google.it) on the left side of the page on any mouse For example, if there is a button named "Home" and the user clicks on it, then it will open two pages home.htm and www.google.it Is there a way out? I am trying to use a simple JavaScript code but it is not working with the above) Document.addEventListener ('click', function (event) {if (/ * your disabled check is here / /) {// event Micro Kill event.preventDefault (); event.stopPropagation ();} // this is the event not mandated by law to certain normally proceeding}, to really be able to // event capturing!); This answer is made on the previously answered question.

java - How do I pass an int from my main to method for calculations? -

Trying to create a program where the user inputs 2 numbers in my head, the menu method shows that Depending on what the user wants to do using those two numbers using a switch statement, then 4 other methods will be based on the option of selecting from the menu based on calculations. My problem / question is how can I pass my 2 stored entities from my main collection to calculate in my other 4 ways? My solution was to ask in my menu method and transfer the process of inputting 2 integers, but my instructor specifically asked to pass the inputs in the main ways. Even what I have so far edit I know that this code compiles and works, which I It was supposed to have 5 links code that asks 2 integers in my head instead of my menu method EDIT public static zero main String [] args) {scanner KB = new scanner (System.in); // Keyboard input allows input from the menu; // menu catches System.out.print ("\ n \ nPress ENTER to continue"); Kb.nextLine (); Iainmen = M...

ldap - Active Directory Searchable Filters -

Is there a way to ask a company's active directory server to get a list of discoverable features? Organizational Unit However, some companies may choose not to use some of these fields and others may use those fields not in the above list. Are there. The problem I am trying to solve, allow the customer to specify a searchable list from their AD installation and specify a search filter to reduce the list of users or groups to select them. Are there. Using LDAP, you can get all the possible attributes from Root DSE's Scotcema entry. You should first ask such as: ldapsearch -s base-b "- dn = administrator, cn = users, dc = domain, dc = com-w 'Password' -x-H192.168.3.10 Object Class = * SubmasyuContrary which returns NN: Subscima concurrently: CN = Assemble, CN = Schema, CN = Configuration, DC = domain, DC = COM Then, like a query: ldapsearch -s base-b "cn = gross, cn = schema, cn = configuration, dc = domain, d "COM =" - ...

jquery - Partial View Update using Ajax refreshing the whole page -

I have a controlling mechanism that gives a partial view and I'm calling the controller verb method below from the main index view. . Controller Public Partial Viewer GetEmployee {Entitle Valve} {var employee = db.getEmployeeById (val) back partial view ("_patiel employee employee", employee); } See index which makes partial calls @using (Html.BeginForm ()) {@ Html.AntiForgeryToken () @ Html.ValidationSummary ( True) & lt; Fieldset & gt; & Lt; Legend & gt; Get Employees & lt; / Legend & gt; & Lt; Div class = "editor-label" & gt; @ Html.LabelFor (model => model.Input) & lt; / Div & gt; & Lt; Div class = "editor-field" & gt; @ Html.EditorFor (model = & gt; model.Input) @ HTML.ValidationMessageFor (model => model.Input) & lt; / Div & gt; & Lt; P & gt; & Lt; Input ID = "GetEmp" type = "submit" value = "run" /> & Lt; / P & gt...

Internet Explorer 11 no such interface supported with javascript window.open() function -

I have two machines at work, both Windows 7 64 bit machines on them Internet Explorer 11 > and the requested page is never opened. By researching this, if it was found that Microsoft has to install the latest cumulative update for Internet Explorer to fix this problem: This problem is already installed on both systems. This error still occurs, though IE has been installed with patches. For that matter, all existing MS updates / patches have been installed on both systems. Any ideas on this ?? To make sure and what to try? Of course, they can use Firefox or Chrome but IE can sometimes be used ... UP !!! UPDATE It looks like IE 11 version 11.0.9600.17280 does not have this problem, while version 11.0.12 is disturbed by running on Windows 7 64bit machines. verified Do that you have installed this Microsoft update: Windows 7 You control panel & gt; Programs & Features & gt; See installed updates, and see 2936068 Windows 8.1 ...

Regex match multiple elements -

I have regex that I'm trying to match specific function parameters here I Trying to match the text: addFill (path: svgjs.Element, Pattern: pattern, docMaxSide: number) {pathFillId (path)} In this example, I want to match the criteria with the words "path" "pattern" and "doctormax side". I want to make sure that it does not match the word "path" in the second line (where I'm calling PathfillID). Here's my current regedx: \ (. *? (\ W +) :. *? \) Broken Down: \ ( find the open feet (\ w +): one before a colon Occupation of the word . *? There may be more stuff after the colon \) Do parens Right now, it will only match the first item, the "path" but I need to match all the words mentioned above. Update: I should have been more specific, it should only match if this is the function parameter. For example, I do not want path1 to match: var path1: string . The difficulty is coming with th...

git - How to make pre-receive hook ignore commits already submitted -

Text after "itemprop =" text "> I commit to the message of checking if it is a valid JIRA issue on the beginning, to obtain a pre-approved The hook is there. But I have some old commitments that are not fit in my pattern (they were created long ago) Example: A - B - C - D - E - F ^ ^ | | | | _ Basic / Master A: This is where my basic / master numeral A, B, C and D: he commits, in which a valid Committed message (and they should not, they are really old) E and F: They're okay with valid messages. When I try to run: Git Push Original HEAD: Master This is just a fast forward Committed remote stores are already on) I would like to find out my pre-received script 'likes to make it, and commit to the validated message A, B, C Do not try, D, E and F My previously received script receives 3 parameters: 'A', 'F' and 'Refix / Head / Masters' My pre-received script is running: git rev-list A..F thanks / code...

Git-Annex hangs -

I'm experimenting with git-annex and I think I have to do something wrong. I have GIT Annex installed on the machine. I did the following: $ mkdir annex $ cd annex / $ git init initial blank GIT repository / annex / Git/ $ git annex init "test data" init test data is fine (git in the recording state ...) $ git annex add --backend = SHA1 $ Git commit -am "initial repo" initial commissions on branch master Nothing for $ touch test.txt # test.txt contains a line "This is an exam" $ git annex add Add to test.txt At this time, mer Command Line dropdown - Jiaiti Add annex what it takes to be able to meet anyone know what's going wrong? The problem was ended

python - Poor sympy performance -

I use Python 3.4.2 on Windows 8.1 (x64) using Simply 0.7.5 (via PIP) I am here. Please consider this short program: Import for import sympy import time = time.time () in category (100): sympy.Point (12345.0, 54321.0) print (' Passed (ms): ', (time. Time () - start) * 1000) This takes about my machine 22 seconds to execute. What am I missing here? Simply By making the point s temporary, the point numbers are automatically converted into a rational number. This can be a good thing (eg if you want to avoid the exact loss of floating point), but may be very slow ( lot ) rational s pass To disable conversion on Evaluation = False , for example % timeit sympy.Point (12345., 54321.) 10 loops, best 3: 31.8 MS per-loop% timeit sympy.point (12345., 54321., evaluation = false) 10000 loops, the best 3: 22.3 per loop per

html5 - magento search form and jQuery conflitcs -

I am using magenta for my online store, but by joining jQuery with my page on my page I am here. When I add: & lt; Script src = "// ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> This creates a search form field in my header stop function. I tried to apply a notation to my code but it is of no avail. I am using jquery flexslider: $ (function () {SyntaxHighlighter.all ();}); $ (Window) .load (function) ($ ('flexiler'). Flexslider ({animation: "slide", start: function (slider) {$ ('body'). RemoveClass ('loading'); }}};}); Can I have any advice on how to correctly implement any notation, or if it is also the direction, then to withdraw and run this search form Need to go Thanks! a confolict jquery helped me & lt ; Script Defer src = "http://dev.tavik.com/skin/frontend/rwd/default/js/homepage/jquery.flexslider.js" & gt; & Lt; / Script & gt; & Lt; Script src ...

Python: How to read text between two empty lines into a string -

I am beginning with programming and Python, and I'm writing a script to stuff with .rt subtitle files Am My problem is that I do not know how to: Read through a file, analyze the text between the beginning of the text and the first blank line, and then between the blank line and the next empty line to the end of the file (for example , Calculate the length of a part like "analyze", convert the second part to the numbers etc.). You can read about the .srt format specification and see an example (type: plain); There is an empty line at the end of the file, I want to compare the number of characters in the comparison of the display time / duration of each subtitle. From the beginning of the file, each subtitle (with its number, duration information and text) is separated from an empty line (a "\ n", I would like them sth like if "N" line and line (line) == 2: ). Time Code is always a "->" And always ends in three digits, so if I have a...

unit testing - How to test whether a React Component contains another component with jest? -

I am trying to use jest-cli to test whether a response component has its output in the second Is the component. Designer Page Component [...] Top TopBar = Required ('../class / Layout / topbar .js'); Var Designer Page = React .createclass ({getInitialState: function () {var state = {}} return state;}, render: function () {Return ( & lt; topbar / & gt; Lt; / div & gt;)}}); Module Exports = Designer Pages; Topbear component / ** @jsx response Dom * / var response = required ("response"); Var TopBar = React.createClass ({rendere: function () {Return (& lt; nav className = "top-bar"> );}}); Module.exports = TopBar; Now, I want to test whether the DesignerPage component has TopBar component. Here's what I should do: / ** @ jsx response Dom * / jest.dontMock ('../../ src / js / pages / designerpage.js'); Describe ('designer page', function () (this should be 'topbier', function) (var respon...

ios - xCode6 how to export an app with .plist for enterprise distribution? -

Image
I have an IPA with an app. I'm trying to upload an app to the website of Plist. The screenshot below is from the website. I noticed that xCode6 has removed the checkbox to save for both "advertising hawk" and "enterprise" delivery options for enterprise delivery. I'm signing an app with a profile from the $ 299 / year Enterprise program. Still I did not get any plist. How can I deliver an app using Xcode 6 to get the Enterprise Plus option? Here I have seen and looked at xCode5 (there is no such checkbox in xCode6) This is not using Xcode, But as a fallback you can only manually / programmatically edit the plist file. I do this because my constant integration distributes the server build, so I can not use the GUI of Xcode to create the plist file. An enterprise distribution here is copied from .plist looks like this):

c# - Create Script Component as Source Programmatically -

I am programming on a package with a data flow function containing a script component as a source. I am able to add packages, data flow tasks, and a script component. Does anyone know how to make a sauce? Here's my class on the single method I'm working on: using the system; Using System.Collections.Generic; Using System.Linq; Using System.Text; System usage threading. Task; Using DynamicPackageCreator.Models; Using Microsoft.SqlServer.Dts.Runtime; Using System.IO; Using Microsoft.SqlServer.Dts.Pipeline.Wrapper; // Alias ​​DtsColumnDataType = Microsoft.SqlServer.Dts.Runtime.Wrapper.DataType to prevent ambiguity; Namespace DynamicPackage Creeter {Public class DtsClient {Public Zero CreatePackageWithDataFlowAndScriptSource (string file path, string dataflow, string source name, list & output; output definition; output definition) {// package package pkg = new package (); Pkg.Name = Path GetFileName Without Extension (File Path); // Create dataflow executable e = ...

Joomla 3 articles category template override not working -

मैं टेम्पलेट \ मीडियाविल्गा \ html \ com_content \ category \ में स्थित फाइल न्यूजलिस्ट.php के साथ एक लेख श्रेणी के टेम्पलेट को ओवरराइड करने का प्रयास करता हूं। Newslist.php मैं इस फाइल को श्रेणी सेटिंग्स में वैकल्पिक लेआउट के रूप में सेट करता हूं, लेकिन यह काम नहीं करता है। मैं क्या कर रहा हूँ गलत, डिफ़ॉल्ट श्रेणी ब्लॉग टेम्पलेट को ओवरराइड कैसे करें? यदि आप डिफ़ॉल्ट श्रेणी ब्लॉग टेम्पलेट को ओवरराइड करना चाहते हैं, तो इसके लिए उसी नाम की आवश्यकता है डिफ़ॉल्ट करता है इसे आज़माएं: 1) फ़ोल्डर \ टेम्पलेट \ मीडियाविल्गा \ html \ com_content \ category \ 2 में घटकों / com_content / views / category / tmpl / में सभी फ़ाइलों की प्रतिलिपि बनाएँ और उन्हें संपादित करें और "गूंज" को जोड़ दें यह मेरा ओवरराइड ब्लॉग है फाइल करने के लिए 'php' " यदि आप आउटपुट देखते हैं, तो आप इसे संशोधित करना शुरू कर सकते हैं।

android - get item view type in adapter returning only 1 item -

I have a custom adapter that will increase the two layouts according to a certain condition. Only 1 item is returning to GetItemViewType status, while there are two and when I present it in the list, the adapter is not the other with a layout, and I can see in my list that there is a place left for it, but Its empty here is my code Enter the code here Public class ListViewAdapter ArrayAdapter and lt; NewsFeed & gt; {Private Static Last Interval: missionLayout = 0; Private static final interval badge layout = 1; Private Treascape mSeparatorsSet = New TreeSet (); Public catalogs (adapter) (super {city newsfid.activity.ece, r.latout.activity_activitabine_news_prod, newsfeed); } @ Override Public Intimate Image Type (Int Position) {Return M.Sp.CatternConnect (status)? Mission Layout: Badge Layout; } @ Override public view getView (integer position, seeviewview, ViewGroup parent) {ViewHolder holder = Faucet; Int type = getItemViewType (status); System.out.println ("getView...

javascript - how this for loop determines when to break the loop -

I have encountered a different type of loop which I do not normally see or do not use. I tried to understand it, but this process is even more confusing. There is no check method to break the third argument or loop. Here it is recursive on an array and prints its value. In fact, it faces the 'undefined' value for a certain index, but I'm not telling it to break when it will face an undemocratic encounter. Please help me break the puzzle ... (function () {var a = [1, 2, 3, 4, 5, 6, 7, 8, 9]; (var i = 0, value; value = a [i ++];) {document.write (value + '& lt; / br & gt;'}}}) (); In Javascript, when you use the array length Beyond access array elements, you do not receive a boundary check error, ret blue value is related to undefined which is related to false when used as a boolean - Thus the loop termination when the end of the array reaches the end. If any array element is undefined or any other value that is in the form of a fal...

multithreading - C# Task ConfigureAwait -

Thought that I was handling the ConfigureAwait , then I tried to do one experiment. I understand that configure (wrong) will only make a difference when the synchronization context occurs. ASP, WPF, etc. should be the reference, but the console applications and service applications should not be. To see how this works, I created a Web API app and included the following method: // API / Value / 5 Public Async Task & Lt; String & gt; (Enter ID) {var syncCtx = SynchronizationContext.Current; Int startThreadId = Thread Present. Thread Managed Trades ID; Waiting for work. Delay (timespace.formsends (3)). Configurable (true); Int endThreadId = Thread.Centrantthith Managed Trades ID; Return "Start Thread ID:" + startThreadId.ToString () + ": Finished Thread ID:" + endThreadId.ToString (); } I predicted that ConfigureAwait or ConfigureAwait is not set to true , I should see My first few tests show that with the right set as above. Later t...

ios - Putting a UIViewController in a XIB makes constraints disagree with frame -

Image
A strange 16pt horizontal padding barrier is placed in the immediate child of the UIViewController's view Add a UIViewController to a XIV file in XIC 6 UIViewController's view Click the pinning barriers button See if it wants to add 16pt distance in its supervision after IB-1 Where is this discrepancy coming from is? How can I get my review to be on the banks of the observation? Pop-up in pin barriers, uncheck the "barrier in margin". Here are some more discussions of this feature:

Splitting screen animation in Android java -

Is there any way to create an animation, where the current page of an Android application is split between and both sides Then go to another page? Here's how I will pass it: Create a screen Divide a bitmap () bitmap into 2. () Animate 2 bitmaps.

c# - Filtering RadGrid by ComboBox -

My problem is that when I try to click the cambode inside my Radgrid, it does nothing . & lt; Telerik: Permalink "RadGrid" runat = "server" DataSourceID = "TestReleaseInformationSource" ShowStatusBar = "true" OnItemCommand = "RadGridItemCommand" OnRender = "Radgrid_prerender" Allow DisabledMatic Exceptions = "True" EnableLinqExpressions = "false" AllowautomaticDelatases = "True "Allow paging =" correct "Autogrentech column =" false "allow filteringBickle column =" true "& gt; & Lt; MasterTableView DataKeyNames = "PrimaryKey" & gt; & Lt; Columns & gt; & Lt; Telerich: Allow gridbound columnsFiltering = "True" Unique name = "TeacherLostname" DataField = "TeacherLostname" header text = "last name" & gt; & Lt; FilterTemplate & gt; & Lt; Telerik: RadComboBox id = "radCo...