Posts

Showing posts from June, 2012

change json file by bash script -

I need your help to solve the following problem: I have a JSON file that looks like this: {"key1": "value1", "key2": "value2", "key3": "value3"} How do I create a new key Can I add "code4" to "code4": "value4" ) by Bash script? Thank you : Li> On Debian-based systems such as Ubuntu, you can call it sudo apt-get jq install on OSX, with a homebree, install Jq For example, depending on the following input string - output stdout : jsonStr = "{" Key1 ":" value1 "," key2 ":" value2 "," key3 ":" value3 "} ' Remove "key3": jq 'del (.key3)' & lt; & lt; "$ jsonStr" value with value "value4" Add the key "key4": jq '"{1 key4": "value4"}' & lt; & lt; "$ jsonStr" Change the value of the...

events - Check if Screen is Touched -

In Windows Phone 8.1, how can I trigger a method every time (with the command bar exception) or other button s)? I can use the button on a large scale, but it seems that ... horrible. I will have some TextBlock s on the screen and I still want to trigger those methods, even if these things are touching. So basically, I'm looking for a method which if any button is not touching, then it will fire. I'm seeing a large number of Windows Phone APIs, but it's challenging, because I'm not really sure what I'm seeing. I think the event of PointerEntered : // For example, the main page constructor: Window. Present. Core window Pointer + = core window pointer; Private Zero CoreWindow_PointerEntered (CoreWindow Sender, PointerEventArgs args) / / Debug your code here. WrightLine ("touch screen"); } Note that you have two more good events to play.

jquery - In jqGrid the Delete Icon is not Clickable -

itemprop = "text"> If I have a line result and try to hover over the deleted icon, then it will not get the focus (clicking Is not qualified)). I have the setting of the search icon next to the deleted icon and when I put it up, it will not respond until the cursor is at the extreme right of the icon, so I think that the deleted icon This is the case, but there is no place where I place the cursor will not react. It's like mouse's hover action offset offset. It depends on whether you are editing inline (cell editing) or editing dialog box Using If you are using the editing dialog, there are some things to check if you have the following: jQuery ("# ​​Grid"). JqGrid ({ 'cellEdit': incorrect, 'cell delete': wrong, 'cell-end': wrong, and then in the editing options, you can set del or edit and other icons Edit: {url: '@ Url.Action ("methodname", "controller"): jQuery ("# ​​grid"). JqGrid...

WSO2 ESB how to handle soap operations independently -

Image
I need to comfortably connect "every one of my soap service" to the service. In I Wso2-esb I With a predefined wsdl, a new proxy service is defined, so far so good, I have published the service and I can "see" the operations from Soap-UE. Now I need to define an implication (I think), my first problem is that I need to distinguish between op1, op2 and op3 because every soap action Goes to a different comfort service what kind of mediator does Thanks! This is very similar to Escannary where you have any message in the form of EOP No value, to use SOAP header value for routing. Well, what you are asked for the SOAP operation, you have to get the value of SOAP header, here's a sample proxy: & Lt; Property name = "MY_SOAP_ACTION" expression = "received-asset ('action')" scope = "default" type = "STRING" /> & Lt; Log level = "custom" & gt; & Lt; Property Name = "...

c# - How to Serialize a ListItem Stored in Session -

I have this code that works fine on my local server: if (Page. IsPostBack) {string [] Question = New string [20]; String [] answer = new string [20]; For (int i = 0; i & lt; lstQuestions.Items.Count; ++ i) {question [i] = lstQuestions.Items [i] Text; Answer [i] = lstQuestions.Items [i]. value; } Session ["question"] = question; Session ["answer"] = answer; If (session ["qalist"] == zero) {list & lt; ListItem & gt; Qalist = lstQuestions.Items.Cast & lt; ListItem & gt; (). ToList (); Session ["qalist"] = qalist; } And {list & lt; ListItem & gt; Qalist = (list & lt; ListItem & gt;) session ["qalist"]; LstQuestions.DataSource = qalist; }} And {if (session ["question"] = null & session ["answer"]! = Null and session ["checklist"] = null] {list catalogs> Qalist = (list However, when I go to a web server, I get the "System.Web.UI.WebControls.ListItem"...

Through bash shell script, i am trying to read yearmonth from file name -

एनबी: इस सवाल का पालन के माध्यम से bash shell script , मैं एक फ़ाइल नाम (FACT_PEOPLE_201401.txt) को पढ़ने की कोशिश कर रहा हूं। फ़ाइल के लिए `एलएस -1 $ {OFSR_IN} / FACT_PEOPLE _ *। Txt में file_name = 'basename $ {file} `एक्स्ट_ युयर =` प्रतिध्वनि $ {File_name} | कट-सी 13-16` # YEAR Ext_Month के लिए = `प्रतिधारा $ {File_name} | कट-सी 17-18 '# महीने के लिए - एक्सचेंज को निकालने का प्रयास $ {EXT_Year} गूंज $ {EXT_Month} EXT_YEARMTH_1 = $ {Ext_Year} $ {var} $ {Ext_Month} # सम्मिलन वर्ष और amp; माह गूंज "\ $ \ $ एचआर_आइरमॉनथ = $ {EXT_YEARMTH_1}" & gt; & gt; $ {OFSR_CFG} / pmserver_OfsrHRSPeople05Loa.prm # यहां मूल्य को आउटपुट करना मैं आउटपुट फ़ाइल config.prm में वर्ष महीना (EXT_YEARMTH_1) का मान प्रिंट करने का प्रयास कर रहा हूं गूंज "\ $ \ $ HR_YEARMONTH = $ {EXT_YEARMTH_1}" & gt; & gt; $ {OFSR_CFG} /pmserver_OfsrHRSPeople05Loa.prm लेकिन मैं सही वर्ष 2014/01 जैसे प्रिंट नहीं कर पा रहा हूं। इसके बजाय मुझे आउटपुट के रूप में $...

javascript - Why do some angular $scope functions "return" an operation? -

I've got some code that looks like this: $ scope.open = Function ($ event) {$ event.preventDefault (); $ Event.stopPropagation (); Return Scope Open = true; }; Why is this returning an assignment? What does it do? Is there any advantage of doing this or not? This is basically: $ scope.open = Function ($ event) {$ event.preventDefault (); $ Event.stopPropagation (); $ Scope Open = true; Return Scope }; The advantage is that it saves a line of code, probably not worth it. This can also be compiled with a cryptographic code, which was originally viewed: $ scope.open = ($ event) - & gt; $ Event.preventDefault () $ event.stopPropagation () $ scope.opened = true The coffee script always gives the result of the last line in a method, so it can return a value from those tasks You will normally expect nothing to happen again.

Inserting data in cassandra without puting in single quotes using cql java driver -

I have trouble troubleshooting those single quotes for ASCII / timestamp columns and other types like int, decimals, Boolean etc. is not putting. The data comes from another DB / table, which is a SQL. I have all the column data as strings. I do not want to format every column data to check empty values ​​and then decide to keep the quote. Whether using ready statement, it is possible to prepare the inserted data in value or whatever If you do not want to write a loader who uses a ready statement (via the CQL driver .. which is a good idea), I can think of another method. To import without using single quotation marks, you should be able to complete it with the COPY FROM CQL3 command (Setting the QUOTE parameter for an empty string) needed. If you can dump your RDBMS data into a CSV file, then you should be able to insert those values ​​in the cassandra in such a way: COPY myColumnFamily (colname1, colname2, colname3 ) With '/ home / myUser coat / rdbmsdata.cs...

Slow performance on MySQL 5.6 trigger -

I have a large table with 80 million rows and triggers that update two other tables, all of them are Tokuthi Server Parcano 5.6 is running create table 'main' (`id 'int (11) tap atangment, timestamp's timestamp tap default cURRENT_TIMESTAMP,` ip_addr` varchar (50) null DEFAULT '', 'Username' varchar (255) tap default ''. Primary key (`id`),) engine = tokudi. is the trigger code if NEW.ip_addr ; & Gt; "" THEN - Get the current oldest date - set @maxdate: = now (); Set @maxdate: = (choose listeen from uniq_ip where data = NEW.ip_addr); Include in the UIIIDID (`data`,` total`, 'lustine') (new apiadar, 1, newtemstamp, @sunet) Key duplicate key update total = total + 1, alstein = latest_date (nuitimestamp, @ maxdate ); end if; - Get all the prices at one time, its indexed query comes from the index. If NEW.username & lt; & Gt; "THEN" - Current Date Date Set: @maxdate: = (Choose listseen from uniq_us...

Does python alter the parameters if not passed while executing a function? -

उदाहरण के लिए: # params def symlinks के साथ फ़ंक्शन का निर्माण (release_path, deploy_to, Function_file, roll_back = false, is_file = false): # फ़ंक्शन सिम्लिंक्स (रिलीज़पेथ, डेपरपाथ, सेटिंग्सफ़ाइल, is_file = true) का इस्तेमाल करने वाले सभी पैरामों के साथ कुछ करना इसलिए कई तरीके हैं अजगर में कार्य करने के लिए मानदंडों को पारित करना, ऊपर एक वैध है? मैंने सिम्लिंक्स (रिलेपेथ, डेपेरपथ, ट्रू) की कोशिश की लेकिन ऐसा लगता है कि यह रोल_बैक को प्रभावित कर रहा है क्या रोल_बैक परम अभी भी गलत है? आपके प्रश्न का उत्तर खोजने के लिए सबसे अच्छा तरीका , का प्रयोग करेंगे। आप इसके साथ खेलकर बहुत कुछ सीख सकते हैं। आयात की जांच करें inspect.getcallargs (सिलीम्क्स, 'रिलीजपाथ', 'तैनातपथ', 'सेटिंग्सफाइल', is_file = true) = & gt; '' तैनाती ' / html>

javascript - How do I get the value of an object -

Image
How do I get an object's value? No: I do not want to use it, foreach, $. For each one I want only one value. Thanks Which price would you like? How to use the highlighted property: var value = activeContract.DisembarkPlace;

How to use jQuery to print a string to the printer -

How do I print a string for the printer using jQuery? I have a print icon button on a page and I want to print a string on the printer. how can I do this? I have finished using print.js - // jQuery "printThis.js" plugin file and "PrintThis.css" style sheet function create print notifications (print button element, notification bar) {//, copy the devil, remove icon, add line break after date and then Print Worksx = $ (PrintButton Element). Parent (). mother-father (). Clone (); . X.find ("I") delete (); After x.find (". ReportedDate") ("& Lt; br \ & gt; & lt; br \ & gt;"); X.printThis ({loadCSS: "../ material / PrintThis.css"}); // CSS hidden buttons and right date returns aligns right; }

html - Scraping a page with awkwardly formatted JSON in python -

I am scraping a webpage for data and it has a format: & Lt;! - Web header here - & gt; ["Foo": "Bar", "Foo 2": "Bar 2"}, {"Foo 3": ["Hello", "World"], "Foo 4": "Bar 4"}, ... ] & Lt;! - Web footer here - & gt; The issue is that JSON appears on the page with other content, and within the quoted list in the JSON list in the source of the page, inside the 'Pre' tag, other HTML tags inside JSON Therefore with: & lt; Pre & gt; "[[" Foo ":" bar ", & lt; p & gt;" Foo2 ":" bar 2 "& lt; / p & gt;}, ...]" & lt; / Pre & gt; Is there a way to capture this unstable formatting and get a list of JSON objects, which is given to JSON-Objects of the string-off-a-list? Preferably getting rid of embedded tags in this process? Edit: I have now installed and started learning Sundarasup 4 recommende...

python - Getting Function name and arguments -

I have come to this situation while writing code in Python for my position and started thinking about this problem. The problem is given in a string in which the function is named with its logic, how do we get the number of arguments and logic names in the function. My first thought was: s = 'func (a, b)' index = s.find ('(') if (index! = -1) : Arg_list = s [index + 1: -1] .split (',') Func_name = s [: index] But as I thought and started, I realized that What function is specified within the function, which has its own logic? func1 (func2 (a, b, c), func3 (d, e)) With the above approach I will end with the correct function name but in arg_list ["func2 (a", "b", "c"), "func3" "D", "e")] Usually this How to solve the situation? If your language looks like python, use Ast.parse () : Import ast parse (s): tree = ast.parse () print ast.dump (tree) parse ('f , B) ') ...

c# - How to download a scrollable HTML page -

I want to download a webpage from tumblr, so I can clear it with images - Though (once you log in), the page continues to load the images, as you scroll forward most of the downloading of the page in C # What's the best way to clear it? You can win webbroser control, fire document loading event complete Hope this help!

c# - Why would an interface implement another interface? -

I list & lt; T & gt; was seen and it was seen by the iiLIT & lt; T & gt; , Icicleing & lt; T & gt; and IEnumerable & lt; T & gt; (among others) Then I will call IList & lt; T & gt; Went to see the definition of and found that it was in the icon selection & lt; T & gt; and IEnumerable & lt; T & gt; . If they work as "contracts" and we do not write the real code on them, then what does the interface implementing another interface mean? Is this implementation cumulative? If so, then IList & lt; T & gt; implies iconaching & lt; T & gt; and IEnumerable & lt; T & gt; , list & lt; T & gt; Only IList on T & gt; Should not be sorry, if my question is confused, then I am just confused. If they act as "contracts" and we have no real code What does it mean to implement an interface to another interface? Interface support the heritage and prov...

Regex to check a specific kind of email address -

Email addresses are in this format: name.lastname@company123.com Maximum length = 64 characters for the entire address Maximum length for the 'company123' = 10 letters (there are 3 separate company names, the longest is a 10 character) If we '@' and ' Com 'which leaves 49 characters for' name '. I have it: [A-Za-Z.] {48} @ | Company 123 | Company 45 Company 67. Edit: I have finished it (according to the advice of @SworWers) ([a-zA-Z] {2, 24}). ([A-zA-Z] {2,24}) @ (| Company 123 | Company 45 | Company 67) \. (Com) You are currently saying "48 characters in the first part of that letter Or should be duration ", it should actually be between 1 and 49" ... possibly numbers can also happen? The domain portion of your Reggae can be listed like that before or it can match similarly but in between 1 and 10 characters, the last option: [a] -zA-Z \ d.] {1,49} @ [a-zA-Z \ d] {1,10} \ com

cocoa - NSCollectionView lazy-loading like behavior -

I'm trying to get behavior like lazy loading from my NSCollectionView. (Honestly I thought it was, like a UITableView - seems like a clear lapse) Anyway, I am displaying images in cells, and to load images As they are about to scroll into the scene, and unload them after leaving them. This is for a research tool and it does not need to be beautiful - that is: the content can be in "pop". Any thoughts? My first idea is to find some kind of footage in the collection when they are on the screen, but drawRect is being said many times, far more often than there are scenes on the screen. As you mention, NScollectionView Especially if there are so many images inside the cells that create performance related problems, I resolve this problem in this way. There may be a better solution but as far as it is working fine for me, for a long time I have seen the code display with the tool and did not see any downwards -. (Zero) windowDidLoad {// Here is the superviso...

Bootstrap 3 with Skrollr site getting cut off on ios? -

I am building a portfolio website for a friend. In an effort to make the site responsive and artistic, I decided to pull Twitter Bootstrap and Scholar. I saw that the site is being cut at a certain point in Safari in iOS, has there been any other part on this issue before? I have provided a link below, if any one clarifies. Thank you! A lot of people (including me) are having trouble using the scroller on mobile devices. To use both "Fixed" and "Relative / Completed" status at the same time, you have to put all the divs that are # skrollr-body though The real problem is that your scholar is getting confused if your scroller-body height is raised. You can try inserting forceHeight: false inside your skrollr.init () if it does not work , Then the scholar may not know where the end of # skrollr-body is, just insert your empty code after your # skrollr-body and it Give a keyframe it should work fine :)

Android - Async downloads all files under one name -

I use Async to download all files of one area (walkfaster.mod adventure.mod and climbing.mod) I am doing ) And the links are downloading the correct file, but it saves it under all the name walkfaster.mod. This is my code: package com.dogger20011.mcpemodlocater; Public class v090 activity expansion {public static ending end DIALOG_DOWNLOAD_PROGRESS = 0; Private button startBtn; Personal progress DIOLOG MPEGDLOG; Override public null on @reate (bundle saved instainstate) {super.naught (savedinstenstate); SetContentView (R.layout.v090); StartBtn = (button) FindById (R.id.button2); StartBtn.setOnClickListener (New OnClickListener) {public void onClick (see v) {startdownload (v);}}); StartBtn = (button) Find VVBIID (R.B.ton3); StartBtn.setOnClickListener (New OnClickListener) {public void onClick (see v) {startdownload (v);}}); StartBtn = (button) Search ViewById (R.id.button4); StartBtn.setOnClickListener (New OnClickListener) {public void onClick (see v) {startdownload (v);}}); } ...

NSOperations and iOS architecture questions -

I'm getting deep in the stuff and I have a question from the IOS architecture: * 1. Is it possible to kill my NSOperations / NSOperationsQueue in the iOS system architecture? * 2. What can be done to do this? What kind of situation? * 3IOS is running on low resources and is init'ed with the NSOption queue allocated and new NSOperations queued? * 4 As I read about the NSOperation - they can not run until they achieve the isReady = YES to execute , Or isReady = NO , if still there are still incomplete operations on which it depends. What kind of dependent job can this be? 1) No, it will not work until it hits your entire application. In this case, You will be notified with the - (zero) app. Device: (UIApplication *) application in your app 2) N / A 3) This one 4) Operation queue will process all your NSOperations. NSOperations dependencies are only for you to be equal to "IsReady", you will need to manually change the value.

java - Maven dependencies for Spring beans & Hibernate -

I am trying to define reliance for Spring End; Hibernating on a Maven project on NetBeans is a "Maven Webpap", although I'm using spring only for its bean container - MVC is not a web component of the project is very light and I am doing it myself on the servicing . Here's the question "Why Maven": Maven is on this project for some other components coming in backend. The dependency in pom.xml is as follows: & lt; Dependency & gt; & Lt; Group & gt; JUnit & lt; / Group & gt; & Lt; ArtifactId & gt; JUnit & lt; / ArtifactId> & Lt; Version & gt; 3.8.1 & lt; / Edition & gt; & Lt; Scope & gt; Trial & lt; / Scope & gt; & Lt; / Dependencies & gt; & Lt; Dependency & gt; & Lt; Group & gt; Org.springframework & lt; / Group & gt; & Lt; ArtifactId & gt; Spring & lt; / ArtifactId> & Lt; Version & gt; 2.5.6 & lt; / Edition & gt; ...

JavaScript - Create New Object (Function) Using an object literal? -

I have defined a function with two javascript: size and url : function IconInfo () {this.size = size; This.url = url; } Inside another function I am making a new example of IconInfo and set the property in this way: function SomeFunction () {Var icon = New IconInfo (); Icon.size = 64; Icon.url = "http://somesite.com/image1.png"; } There is no way to create an event like the following example: var icon = new iconInfo ({Size: 64, url: "Http : //somesite.com/image1.png "}); I think this signaling looks better, it sounds more concise and easy to read. =========================== Updates ======== ======================== Based on Tim's reply it is done in the following manner: var icon = {size: 64, url: "http://somesite.com/image1.png"}; I have the following questions. Let me assume that I have 2 works both with exact properties and Constructor logic: Func1 (x) {this.x = x; } Func2 (x) {this.x = x; } And I have...

phpunit - Yii2 unit testing not working properly -

When I am running a yii2 unit test, I am getting the following error Fatal error: Class 'False \ Tests \ unit \ PHPUnit_Framework_TestCase' not found Have you included class PHPUnit_Framework_TestCase?

c# - RedirectToAction with a parameter not working -

I am trying to redirect any other action within the same controller action which is called the index [httpPAGT] Public Action Result Search (String City) {Redirect Reaction ("Index", "Rent", New {Cityname = City}); } This is an index action [HTTP post] Public ActionResult Index (string cityname) {} Am I missing something? You are trying to redirect an action that is searching for a matching action but There is no action in this situation, so you have to get a method to accept the redirect. If you want, you can see this public functioning index (string cityname) {} east>

javascript - How to make a landing page with a full screen image? -

I would like to create a landing page with a full screen image. By this way: I can understand the rest of the things below, but how would I go about covering the entire screen? This is the background for title tags If you have 153 in the stylish_policy CSS 163 go to line .header {display: table; Status: Relative; Width: 100%; Height: 100%; Background: URL (../img/bg.jpg) No-Dual Center Center Scroll; -WebKit-Background-Size: Cover; -MOZ-BACKGROUND-SHAPE: COVER; Background size: cover; -O-background-size: cover;} Backgro-size This is a trick to cover the screen --- Edit height and width should be 100% so that the picture fits on the entire screen on any media.

php - http_host with and without www -

I have a message to appear in PHP, if the domain is already out of some existing ones redirected to the account . For example, if I'm domain www or non www, then I'm trying to run: if ($ _SERVER ['HTTP_HOST']! = ( 'Xxx Co.uk' & amp; www.xxx.co.uk ')) However, it seems like working like i xxxx.co.uk (which is a Other domains point to their account) If the content still does not appear What is obvious, something is clear from above? Use "" instead of "' ( $ _SERVER ['HTTP_HOST']! = ("Xxx.co.uk" & amp; If the above does not work then try one at the bottom if (($ _SERVER ['HTTP_HOST']! = "Xxx.co.uk") & amp; amp; ($ _SERVER ['HTTP_HOST']! = "Www.xxx.co.uk"))

html - Table and body design mismatch -

मेरे पास तालिका संरचना का पालन है & lt; table & gt; & LT; तालिका & gt; & LT; thead & gt; & Lt; tr & gt; ... शीर्षक टेम्प्लेट ... & lt; / tr & gt; & Lt; / thead & gt; & Lt; / तालिका & gt; & LT; tbody & gt; & LT; टीआर & gt; ... & lt; / tr & gt; & LT; टीआर & gt; ... & lt; / tr & gt; & LT; टीआर & gt; ... & lt; / tr & gt; & Lt; / tbody & gt; & LT; तालिका & gt; मेरी समस्या यह है कि डटारो और हेडर पंक्तियां एक-दूसरे के साथ गठबंधन नहीं हैं। संपादित करें: मैंने अपनी ग्रिड को पॉप्युलेट करने के लिए जेकग्रीड का उपयोग किया है I तालिका संरचना जो jqgrid उत्पादन ऊपर की तरह है अगर मैं टैग के भीतर लपेट नहीं करता, तो पहले अंदर गायब हो जाता है। आपके पास बहुत वाक्यरचना त्रुटियां हैं यह सामान्य तालिका है: & lt; तालिका सीमा = 1 & gt; & LT; thead & gt; & Lt; tr & gt; & lt; th & gt; हेडर टेम्पलेट & lt; / th & gt; & lt; /...

jpa - One-To-One unidirectional relationship -

I have two institutions, ap and apatatus, one-by-one-one-one-one-one-one- In one relationship Only AP should be able to reach epistatus. Epistatus needs to identify only AP, which will also serve as the primary key for epistatus. Basically, Epistatus is like an embedded object, but I want a separate table for it. Here's what I have: My entities @Entity public class AP {@Id @GeneratedValue (strategy = GenerationType.AUTO) @ column (name = "id" , Nullable = false) Private Ent ID; @OneToOne Private Epistatus Epitatus; // Gates and Setters} Entity Public Class Epistas {@Id @Column (name = "AP_ID", nullable = false) Private Ent APID; // gates and satellers} my test public class aparipositoryte {@Autowired APRepository repository; @Autowired APStatusRepository Status Repository; @Test Public Zero Test () {AP AP = new AP (); Apestatus Status = New Epistatus (); StatusRepository.save (status); Ap.setApStatus (status); Repository.save (ap); Status.setApId ...

facebook - FB API App-scoped user id forbids event invitation -

On the FB application (created before April 30, 2014), our website is given the option to choose friends to invite. The website that they create is using JS SDK v1.0. User IDs that return the visitor to this tool are now an app-scod instead of pre-global e-ed pre-200. When such app-scoped users are used against / {event-id} / invited users' end point, a callback callback of true is sent to , but reaching the invited goal friend using the same (Global, Pre-2.0) UID allows the invitation stream to reach its destination (and it appears on the event page) gives). The additional information is that this functionality is being used with a different app ID, every aspect of functionality, i.e. listing a friend, creating events, reading user events, and working on the wall Generally sharing - our issue remains with inviting users to an event with an invited app-script ID. Does anyone have to face the same issue or have any insights that can be used? Edit: An additional i...

javascript - Reverse Accordion Direction -

it is In what direction will I change my zodiac Arctian? - And the access code is 000 I want the slide up / vertical up / up to the aserian - not bottom. Pure CSS would be bad, but if J $ works, then it would be great! :) Thanks for your attention I have customized accordingly so that it comes up ... I think it will help you .accordion .accordion-navigation.active & Gt; A, .accordion dd.active & gt; A {background: # e8e8e8; Status: Relative; Top: 85px; // change this] .accordion .accordion-navigation & gt; A, .accordion dd & gt; A {background: #fiff; Color: # 222222; Padding: 1rem; Display area; Font-family: "helvetia new", "helvetia", helvetica, ariel, non-serif; Font size: 1rem; } .accordion .accordion-navigation & gt; A: hover, .accordion dd & gt; One: hover {background: # E3E3A3; } .accordion .accordion-navigation & gt; .content, .accordion dd & gt; .content {display: none; Padding: 0.9375rem; } .accordio...

Login With MVVM and WPF - Login Object must use in other windows. (Globalization) -

I am very new to WPF and MVVM patterns. I have no experience in windows too. I have created a simple login window _ login.axml, login vvmmdell cs _ dashboard XML, Dashboard View Model CS successfully after login - (we will also select language at login time) I am displaying the username; Selected language in the dashboard window I have written the code like this: public partial class app: application {secure override zero start (startup eventsErgus e) {base.OnStartup ( E); Try {var login = new login (); Var loginVM = new loginview model (); Dashboard key = faucet; LoginVM.LoginCompleted + = (Sender, Args) => {Dashboard ViewModel dvModel = New Dashboard View Model (login veem); Main = new dashboard (); Main. Datacontact = dv modell; Main.ShowDialog (); Login.Hide (); }; Login.DataContext = loginVM; Login.ShowDialog (); } Hold (Exceptional) {East; }} This username and language is successfully displayed in the Dashboard window. But my problem is the two (usernam...

asp.net web api - Getting exception while using itextsharp to convert from html to pdf in web api -

itemprop = "text"> list item I'm getting "uri prefix is ​​not recognized iTextSharp" / Code> Exception After the method of my Web API controller that gets the HTML data and convert it to PDF. [System.Web.Http.AcceptVerbs ("GET", "Post")] Public HttpResponseMessage DownloadPDF (long estimationId) {HttpResponseMessage results = New HTTPPassSpaceMessage (HTTPPttatus code.OK); Try to get the data for method calculation and convert it to HTML string html = objRepository.GetHTML (Estimate ID); // Create PDF var document = new iTextSharp.text.Document (PageSize.A4); Document.SetMargins (20.0 f, 20.0 f, document TopMargin + 20, document. Botomargin); Var output = new memorystream (); Var Author = PdfWriter.GetInstance (Document, Output); Document.Open (); StringRedder Strat = New StringRadder (HTML); Var parseedHtmlElements = HTMLWorker.ParseToList (strRdr, null); Foreach (html) element in crossed HTML analytics document.Add (HTMLEl...

java - The import com.google.api.services.samples cannot be resolved? -

Image
I'm trying to use the Youtube data API to get some search results and I receive the following from eclipse Is getting .. I can not find "at" orbit anywhere on the web , I do not understand why it did not get it. Anyone know? You can find the square in the git repository

javascript - angular js modal popup call factory function -

I am trying to call the factory function in my modal popup but this error returns This is my factory .factory ('PartnerFactory', ['$ http', '$ rootScope', function ($ http, $ rootScope) {var current partner; var partners = [ ]; Var current client; var current site refund {savePartner: function (partnerData) {console.log ("in partner save"); console.log (partnerData); var url = "/ api / partner / createpartner" var datatpost = {Name: partnerData.Name, Description: partnerData.Description, Address1: partnerData.Address1} / $ / Http: // $ http.post (url, dataToPost) .vivet (function (data) {}) .error (function (data) {// return $ scope.showInfoOnSubmit = ! 0, $ scope.revert ()}), getPartners: function () {var url = "/ api / partner / getAllPartners"; return $ http.get (url). Then (function (feedback) {partners = response data; $ Rootscope. $ Broadcast ('handle shared partner', partners); Return partners;})}}}}} moda...

c++ - class template specialization with nondatatype template parameter -

मैं निम्नलिखित कोड के साथ कोशिश कर रहा हूं: #include & lt; iostream & gt; नेमस्पेस एसटीडी का उपयोग करना; टेम्पलेट & lt; typename T, int SIZE & gt; क्लास स्टैक {टी एलिमेंट; T आकार [SIZE]; सार्वजनिक: शून्य सेट एलेमेंट (टी एलएलएमटी) {element = elmt; Cout & lt; & lt; "इनसाइड सेट एलेमेंट" & lt; & lt; endl; }; स्टैक () {cout & lt; & lt; "कन्स्ट्रक्टर" & lt; & lt; endl; Cout & lt; & lt; "SIZE है" & lt; & lt; SIZE & lt; & lt; endl; }}; // इंट क्लास स्पेशलाइजेशन टेम्पलेट के & lt; & gt; क्लास स्टैक & lt; int & gt; {Int तत्व; पूर्ण आकार [आकार]; सार्वजनिक: शून्य सेट एलेमेंट (इंट एल्मट) {element = elmt; Cout & lt; & lt; "इनसाइड सेट एलेमेंट" & lt; & lt; endl; }; स्टैक () {cout & lt; & lt; "कन्स्ट्रक्टर" & lt; & lt; endl; Cout & lt; & lt; "SIZE है" & lt; & lt; SIZE & lt; & lt; endl; }} Int mai...

php - What causes the error 'Not Found SoftDeletingTrait Class'? -

I just updated from Laravel 4.1 to 4.2.7. I'm trying to delete with soft delete: Use SoftDeletingTrait; Protected $ dates = ['deleted_at']; But with this 'Not Soft Delighting Class' error has occurred, what is the reason for this error? Just call it from the 'Brighten' database \ Eloquent \ SoftDeletingTrait; ' Brighten \ database \ Eloquent \ SoftDeletingTrait; The class provides user lucrative {use soft datingset; Protected $ dates = ['deleted_at']; } = & gt; Or & lt; = Go to config / app.php & amp; Add nickname For Larval 4 'SoftDelittingTet ='> 'Lights \ Database \ Supernatural \ Soft DeliveringTat', for Laravel 5 'SoftDelatus' = & gt; 'Illumination \ DatabaseBuzzy \ SoftDeletes :: class'; Use the model or controller file to illuminate \ database \ Eloquent \ SoftDeletes;

c++ - How can I create a vector of virtual class? -

I'm new to C ++, so I decided to work on some small project to improve myself. I try to write a simple chess program with class unit, and class King inherited from the unit #include gt; unit list, string sidepick, int expo, int ypos) {int i = 0; While (i! = 3) {int x = unit list [i] .getX (); Int Y = unit list [i] .getY (); String sidetemp = unlistlist [i] .getside (); If ((X == Expo) & amp; (Y == Ypos) & amp; (sidetemp == SidePic)) {return false; } And if ((X == Expo) & amp; (Y == Ypos) & amp; (sidetemp! = SidePic)) {// Unitalist [i] = Faucet; Back true; } I ++; } Back true; } Virtual Zero Drive (vector & lt; unit> unit list, int nextX, int nextY); }; Class King: Public unit (public: king (string sideplay, int expo, int ipso): unit (sideplay, expo, wipe) {} zero driving (vector & lt; unit & gt; unit list, int next x, int next y } {Int diffX = abs (nextX-currentX); Int diffY = abs (next Wi-turn Y); {(DiffX == 1)} (diffY == 1) (if (valid object...

php - codeigniter migrate to linux server page was not found -

I have corrected it using the codeinter running on windows localhost, but the problem is that when I get to the Linux server Migrating error message '404 page not found' .base_lill has already changed. localhost -localhost / ci / index.fp/test (window) output: successful server -172.16.10.251 / ci / index.php / test- (linux) Output: 404 page not found question Do I have any settings missing to change? Sorry I had to face the same problem. I think the problem is on the sensitive sensitivity of Linux. So I encourage you to replace all your files with the capital letter under the controllers and the model. I managed to solve the same problem using this approach.

sql server 2008 - How to add additional conditions to WHERE clause in SQL pagination query -

I have a pagination query which is executed on SQL Server 2008 rs2 and It looks like: [Client] as TBL [as Client] SEQ WHERE (PDA) as [Customer] SEC Where (as Client ID) Seq.rownum 0 and 10 And it's working fine. Although I have filters and sometimes I want to show the extra code as ... and like stuff but I can not understand where the place to do it is. I tried: seq where seq.rownum between 0 and 10 and the first% zu% but I get an error How to add filtering clauses? you % J% : Seq where seq.rownum between 0 and 10 and the first name '% Jh%'

c++ - How to Overload a method from parent to child -

जानवरों की मेरी कक्षा class Animal {protected: string animalName, sounds, colors, जिस तरह से रास्ता हटाना, रास्ता बंद करना; इंट नंबरऑफलेगेस; बूल हैटेल; सार्वजनिक: पशु () {} // डिफ़ॉल्ट कन्स्ट्रक्टर ~ एनिमल () {} // डिस्ट्रक्टर व्यर्थ सेट एन्निमल (स्ट्रिंग, स्ट्रिंग, स्ट्रिंग, स्ट्रिंग, स्ट्रिंग, इंट, बूल); पशु GetAnimal (शून्य); }; वर्ग वन्यअनिमल: सार्वजनिक पशु (स्ट्रिंग पशु), हमले स्टाइल; सार्वजनिक: शून्य सेटएनिमल (स्ट्रिंग, स्ट्रिंग); }; क्लास तामअनिमल: सार्वजनिक पशु {स्ट्रिंग शिकारी, छुपा स्टाइल; }; मुख्य में मेरा उदाहरण: WildAnimal शेर; शेर। सैट अनिमेल ("शेर", "रोअर!", "गोल्ड", "स्टिक द जीभ आउट", "टीयर द देस", 4, सच); शेर। सैट एनीमल ("हरिण", "पंस"); मुझे "गोल्ड" भाग में एक त्रुटि मिलती है, जिसमें कहा गया है कि मैं बहुत अधिक पैरामीटर दे रहा हूं। मैं कक्षा पशु से जंगली जानवरों को सफलतापूर्वक अधिभार कैसे सेट कर सकता हूं? धन्यवाद! जब आप किसी व्युत्पन्न वर्ग में सदस्य फ़ंक्शन को घोषित कर...

c++ - How does one use inheritance when we have a template class have template pointer -

Template pointer when there is a template class We know that the base class pointers are easily generated The class can point to the object. I created another template class and crossed the base and got generated in it. However, I can not do even with an overloaded = operator, then my equal requirement is required. Please take a look at this because it clearly explains the situation. #include & lt; Iostream & gt; using namespace std; Class base 1 {public: int a; Virtual Init Reset () {a = 0; Return; }}; Class 1: Public base 1 {public: int b; Int reset () {b = 0; Return b; }}; Template & lt; Class T & gt; Square templateclass {public: t * p; T & amp; Operator = (Template Class & amp; B) {this.p = reinterpret_cast & lt; T & gt; (BP); Return * This; } Zero Reset MySpace () {P-> Reset (); }}; Int main () {// Your code here template class & lt; Base1 & gt; * P = new template class & lt; Base1 & gt; (); TemplateClass & LT; Der...

windows - xx is not a valid win32 application -

I have developed a Win32 program using VC ++ 2012 (Express 2012 for Windows Desktop). I chose "Win32" / "Win32 Console Application" while setting up my project. I can run it on Win-7, but failed in POSReady 2009, which is near WinXP when I participated under POSReady 2009, it is shown as the title. Is there a way to configure project properties on VC ++ 2012 or is there any other way to win it? Thank you. You will need to install VS2012 Update 1 or later or VS 2013 Express, and your platform The toolset for "V110_xp" or "v120_xp" is set which is compatible with Windows XP Service Pack 3 / Windows Server 2003 Service Pack 2). The main difference between "v110" / "v120" and "v110_xp" / "v120_xp" is the platform toolset Windows SDK "V110" / "v120" Windows 8.x SDK which makes Windows Vista Or targets later versions. It is not possible to create a Windows XP compatible application us...

python - Matplotlib figure doesn't display correctly when re-opening -

I have an application that I'm running from a python shell. I have a main shape fig, (plt1, plt2, plt3) = pl.subplots (3, 1) I have the following functions : def do_select_features (auto, line): global mode, fig mode = 'features' fig.canvas.mpl_connect ('key_press_event', on_key) plot_wnd () pl.ion () pl. Show () def plot_wnd (): plt1.cla () plt2.cla () plt3.cla () plt1.grid (true) plt2.grid (true) plt3.grid (true) plt1.hold (true) plt1.plot (Rdata) plt1.plot ([rng_current [0], rng_current [0]], [minute (rdata), max (rdata)] 'r', lw = 1) plt1.plot ([rng_current [1], rng_current [1]], [minute (rdata), max (rdata)], 'r', lw = 1) zdata = compression.fill_in (compression.zigzag (normal, curved)) plt2.plot (z Data [rng_current [0]: rng_current [1]], color = 'r') plt2.plot (normal (rdata) [rng_current [0]: rng_current [1]], color = 'b') plt3.plot (diff (Zdata, normal (Rdata)) [rng_current [0]: rng_current [1]], color = 'r...

Strange parse error with C and dlc compiler -

मेरे पास निम्न कोड है: int bitSwitcher = (1 & lt; & lt; n ) + ~ 0; BitSwitcher = bitSwitcher & lt; & lt; (32 + (~ एन + 1)); Int arthShift = x> & gt; n; Int logShift = arthShift ^ bitSwitcher; Int xSign = x> & gt; 31; Int था NegShift = xSign & amp; logShift; इंटेल था PosShift = arthShift; वापसी थी NegShift ^ wasPosShift; पार्स त्रुटि के साथ लाइन है: int arthShift = x> & gt; कंसाइलर भी पिछली पंक्ति में कहता है: वापसी थी NegShift ^ wasPosShift; था NegShift और था PosShift अघोषित हैं, जो मुझे लगता है क्योंकि उनकी घोषणा सीधे या सीधे उपयोग करते हैं ArthShift या अन्य चर जिसका घोषणा arthShift पर निर्भर करते हैं का उपयोग करें। मैं एक प्रोग्रामिंग पहेली कार्य के हिस्से के रूप में डीएलसी संकलक कहा जाता है कुछ का उपयोग कर रहा हूँ यह सुनिश्चित करने के लिए डिज़ाइन किया गया है कि आप विशेष नियमों का पालन करें (उदा: आप केवल कुछ मान और ऑपरेटरों का उपयोग कर सकते हैं) कभी-कभी मुझे ये अजीब "पार्स त्रुटियां" मिलती हैं (यह केवल एकमात्र जानकारी ...

debugging - bug in nthroot using fixedpoint -

My attempt is to exercise 1-45 from the structure and interpretation implemented in Haskell: Fixed point :: (double-> double) - & gt; Double - & gt; Double - & gt; Double Fixed Points Estimated | Error & gt; Abs next estimate = next | Otherwise = Fixed point F is the next count where next = F is approximate average: double - & gt; Double - & gt; Double average A B = (a + b) / 2 avgdamp :: (double -> double) - & gt; (Double -> Double) avgdamp f = \ x - & gt; Average X (FX) log2 :: double - & gt; Repeat double log2 = (/ log2): (a-> a) - & gt; Int - & gt; (A-> A) Repeated F n = \ x - & gt; (Repeating fx) !! N nthroot :: int - & gt; Double - & gt; Double - & gt; Double Nathroot NX IRE = Fixed point (Repeated Egampamp DesignsED $ EKN) 1.0 Where to Be Reflected = Floor $ log2 $ from Integral - Experimentally determined eqn = \ y - & gt; X / Y ^ (N-1) I tested the procedures one by one, they seemed OK. I ...

sql - Looping through different tables of different dates -

We have a legacy application, which has created several tables with the following naming convention: table_20140618, table_20140623, etc., where The date is running the program. I am now trying to clean the database, and have left some of these tables. Each table has two fields: date start and date finished. I want to select the tables (and then skip them) where the date and date of the starred date is not zero, is not zero. At the moment I am using the following questions to select all the tables that begin with 'Table_': such as: from selection (TABLE_NAME) SOCEMA.TABLES WHERE TABLE_TYPE = 'base table' and 'table_%' like TABLE_NAME; I'm not sure how to find all the areas within your fields and get together. I can do this via code, but this means that there should be many hits on the database. Any ideas? This above, after my first comment, but you should be able to change the code to fit your glasses Actually, it will use dynamic SQL to g...

split - php explode string with Uppercase if lowercase letter exists before it without space -

$ str = "हैलो मोटोबेल रिंग्सिंग स्पीच"; लोअरकेस अक्षर से पहले मौजूद होने पर मुझे इस अक्षर को अपरकेस अक्षर से विस्फोट करना होगा। इस तरह से: $ splitted = array (0 = & gt; "हैलो मोटो", 1 = & gt; "बेल रिंग्स", 2 = & gt; "किंग स्पीच"); कोई भी विचार? मैं reg_ex का उपयोग करने की कोशिश करता हूं, लेकिन काम नहीं कर रहा हूं: $ pieces = preg_split ('/ (? = [ए- ZÐ ?? - Я]) / u ', $ str, -1, PREG_SPLIT_NO_EMPTY); var_dump (preg_split ('/ (? & Lt; = [एज़] ) (? = [एजी]) / ',' हैलो मोटोबेल रिंग्सिंग स्पीच ')) // सरणी (3) {// [0] = & gt; // स्ट्रिंग (10) "हैलो मोटो" // [1] = & gt; // स्ट्रिंग (10) "घंटी के छल्ले" // [2] = & gt; // स्ट्रिंग (11) "किंग स्पीच" //}

ruby - How to define model relationships for this Rails app for physiotherapists? -

I am trying to make my first real life rail app, I'm a Ruby on Rail. The idea is as follows: The app shows an overview of practice . Each exercise has a category: string, bodypart: string, instructions: text and An image (this will add using the paperclip gem). Then there is Patient name of each patient: String and Email: String Finally Exercise Plans There is a name in each exercise plan: String and observation of exercises in it. As an user of the app (physiotherapist) I can choose exercise from observation and can email them to a patient. When selecting a PDF form (prone to gem using it), the user (physiotherapist) should be able to record 'repetition' or 'per exercise' per exercise. It should be added to the exercise plan and should be printed in PDF. How can I define ideal organizations in ActiveRecord? I would start with something like this: class Exercise & lt; ActiveRecord :: Base is_im: exercise_plan and class patient & lt; ...

Coldfusion and unscoped variables -

I am currently checking all my functions and components for unscoped variables. I am using a device called to look at all the works, looking at the following code, the WordScript tells me that the "Input" variable on the line 4 in the Unsocked. Is this true and do I need to scope the argument variables if I change it? & lt; Cfoutput & gt; #testit (1) # & lt; / Cfoutput & gt; & Lt; Cffunction name = "testit" & gt; & Lt; Cfargument name = "input" & gt; & Lt; CFSet input = 3 & gt; & Lt; Cfreturn input & gt; & Lt; / Cffunction & gt; FYI does not report any unassipped variables, if I do not change logic variables in function varscoper4. & lt; Cfoutput & gt; #testit (1) # & lt; / Cfoutput & gt; & Lt; Cffunction name = "testit" & gt; & Lt; Cfargument name = "input" & gt; & Lt; Cfset var output = 3 + input & gt; & Lt; Cfreturn output...

osx - How to properly use python modules -

मैंने test.py नामक एक परीक्षण फ़ाइल बनाई है (जिसमें एक वर्ग का परीक्षण किया गया है) और इसे सहेजा गया है दस्तावेजों में (मैक ओएस एक्स 10.9.3) मैंने तब परीक्षण आयात परीक्षण से लिखकर इस फाइल का उपयोग करने का प्रयास किया। हालांकि, मुझे एक त्रुटि मिली है कि मुझे कोई परीक्षा नहीं मिली है। कृपया इस मुद्दे पर कुछ प्रकाश डालें। समस्या ये है कि दस्तावेज़ फ़ोल्डर सामान्यतः नहीं है । मैं दो समाधान के बारे में सोच सकते में > कहीं भी पायथन के पथ में फ़ाइल test.py को ले जाएं। आप इस स्क्रिप्ट के साथ अपना PYTHONPATH पा सकते हैं: आयात ओएस कोशिश:। user_paths = os.environ [ 'PYTHONPATH'] विभाजन (os.pathsep) KeyError को छोड़कर: user_paths = [] (से मार्क Ransomâ € ™ s का जवाब) आप import sys.path ये दोनों फ़ोल्डर्स की एक सूची वापस करते हैं। यदि आप उन फ़ोल्डर्स में से एक में test.py डालते हैं, तो यह दुभाषिया द्वारा देखा जाएगा। उदाहरण के लिए, मैं आमतौर पर / लायब्रेरी / पायथन / / / और फिर मैं import उन्हें सामान्य रूप में कर सकता हूं। मैन्युअल ...