Posts

Showing posts from April, 2011

http - Server side redirect vs Javascript redirect in terms of SEO -

I am making my own short URL website 9o9.in A visitor to a small URL Generates by my site, it will essentially hit your server first but I know that there may be many links to potentially harmful or inappropriate sites which will be reduced by using the service of my site. To make sure that I am not setting the negative reputation of my site, referring to SEO, links to the eyes of the search engines, or the sites rejected by HTTP, do I have the php header () function Like using a server should go for redirection, or should I redirect a JavaScript-based client side? Ok, I know that sensible solution is to prevent users from generating small links to unacceptable sites. But right now I might not be able to apply it because it requires a detailed amount of data analysis or using expensive word filtering API ... Any help is highly appetized. Thank you. A server-side redirect will be less latency, because the browser can start receiving new ones immediately. While with th...

ios - Error "expression is not assignable" on timerBar.bounds.size.width assignment -

I am trying to create a timer bar, but I am getting an error "expression is not assigned" on Timerbar.bound. size.width = 0 (zero) viewDidoadload {[Super Viewedload]; // Setup an additional after loading the view, usually from a nib Self.view.backgroundColor = [UIColor blueColor]; TimerBar = [[UIView alloc] initWithFrame: CGRectMake (0, 0, SCREEN_WIDTH, 5)]; Timerbar Background color = [UIColor whiteColor]; [Self.view addSubview: timer bar]; [UIView CheatVirtuality: 2 Delay: 0 Option: UIViewAnimationOptionCurveLinear Animation: ^ {timerBar.bounds.size.width = 0; } Closing: ^ (BOOL Finish) {}]; } What am I doing wrong? Why can not the value be assigned? You can not set the width of the boundaries to zero!

CSS to keep two DIVs left and right? -

स्रोत है: & lt; आलेख & gt; & Lt; div वर्ग = "फ़ील्ड फ़ील्ड-नेम-बॉडी फ़ील्ड-प्रकार-पाठ-के-साथ-फ़ील्ड-लेबल-छिपा हुआ" & gt; & Lt; div वर्ग = "फ़ील्ड-आइटम" & gt; & Lt; div class = "field-item even" property = "content: एन्कोडेड" & gt; LEFT पर पाठ & lt; / div & gt; & Lt; / div & gt; & Lt; / div & gt; & Lt; div वर्ग = "फ़ील्ड क्षेत्र-नाम-फ़ील्ड-छवि फ़ील्ड-प्रकार-छवि फ़ील्ड-लेबल-छिपा हुआ" & gt; & Lt; div वर्ग = "फ़ील्ड-आइटम" & gt; & Lt; div class = "field-item even" & gt; & Lt; img src = "right.jpg" alt = "दाएं पर" / & gt; & Lt; / div & gt; & Lt; / div & gt; & Lt; / div & gt; & Lt; / लेख & gt; दो डीआईवी को देखने के लिए सीएसएस कैसे बदल सकता हूँ? + ------------- - + -------- + | पाठ पर LEFT | #### | | | #### | | | #### | | | | | | | + -------------- + -------- + i.e। अद्...

How do I protect static files with ASP.NET form authentication on IIS 7.5? -

I have running on a shared host on ASP.NET 4.0 on IIS 7.5 server, but in full confidence. The site is an original "file browser" that allows visitors to login and display a list of available files for them, and of course, download files static files (mostly PDF files) Are located in a sub folder on a site called, e.g. ... The site uses ASP.NET form authentication. My question is: How do I obtain the ASP.NET engine to handle requests for static files in the data folder, so that requests for files can be authenticated by ASP.NET, and users Not able to have a file and grab links to grab files from them? Regards, Egil. Text after "div class =" itemprop = "text"> If you are running the application pool in integrated mode, you can do the following. Add the following to your top-level web.config. & lt; System.webServer & gt; & Lt; Module & gt; & Lt; Add name = "FormsAuthenticationModule" type = "System.We...

ruby on rails - Wicked PDF RuntimeError -

I have installed malicious PDF rail 4, and now I have this problem: runtime error clients controller # show [show] error: failed to execute: [ "C: / Program Files / wkhtmltopdf / bin / wkhtmltopdf.exe", "--footer-center", "Center", "footer-left", "left", "-pakr-right", "right", "file: // C: / users / Rasheed / Aepdata / local / theme / Viwadit_peedif20l4l0l7-9664-l8 xoryq. Html "," c: / user / rashid / appadata / local / theme / disputed_pdf _Janetted_file20141017-9664-zo89le.pdf "] Error: PDF could not be generated! Command Error: Page Loading (1/6) [>] 0% [======>] 10% Error: Failed to load page file: // c / Users / Rashid / AppData / Local / Temp / wicked_pdf20141017-9664 -18xoryq.html (sometimes to ignore the error with error - will work to avoid load-error-management) network error Exit reason code 1: ContentNotFoundError def Show Response_to do | Format | Format.html forma...

java - Update data to file each amount of bytes -

Image
I want to write my content data in every 10kb file in a file. It looks like: Whatever I tried: The file is intestust; FileOutputStream Out; File input = new file (file path); Int fileLength = input.length (); Int len ​​= 0; While (Lennon & lt; fileLength) {len + = Reed (bref); // Write out your data. Write (data, 0, data length); // How to proceed Next 10kb is to read ??? } I wonder if there is no way to move the cursor to the next volume of the bytes? Update : Thank you for @hhought , here's my implementation: file input = new file ( file path); Long file length = input.length (); Byte [] data; Byte [] buff = new byte [data.line]; Long JUMP_LENGTH = 10 * 1024; RandomAccessFile RF = New RandomAccessFile (Input, "RW"); Long step = JUMP_LENGTH + data Length; For (long I = 0; i & lt; file length; i + = phase) {// read in Buffer RF.Sec (i); Raf.read (fond); Raf.seek (i); // Make sure that it is moved to correct the location after writing RF. Write ...

database migration - grails dbm-gorm-diff is updating db -

I am using grails database-migration to update my production db, but it offers a strange behavior is. I went to dbm-gorm-diff and it seems to work fine, but for some reason I'm updating without using 'dbm-update' or updating my file db or if it is deployed in war file is applied. That which I have felt so far, it seems that there is something to trigger an update on any Operation DB on the Prod environment. And I did not know what to do. Have you set up data-> db-create to?

c# - Type conversion and typeof -

After I have made the following declaration in C # Personal IDictionary & LT; ViewModelBase, Type & gt; _routingDictionary; With the following method navigate through public zeros & lt; TDestinationViewModel & gt; () Where TDestinationViewModel: ViewModelBase {// I wish to use something like des = _routingDictionary [typeof (TDestinationViewModel)]} But it does not work and I get a compile error is you can not convert from 'System.Type' 'GalaSoft the .MvvmLight.ViewModelBase' the following are I can solve this by using Navigate through public zeros & lt; TDestinationViewModel & gt; () Where TDestinationViewModel: ViewModelBase, New () {TDestinationViewModelDes = New TDestinationViewModel (); Type destination = _routingDictionary [dace]; } While there is no better way to do this? You have declared the other way dictionary that ViewModelBase is an important and Type should be in the form of a value this should...

playback - Playing Video in SDL 2.0.4 (Theora) -

मैं उपयोग कर रहा हूँ: UBUNTU 14.04 + SDL 2.0.4 + कोड :: ब्लॉक 13.12 - ( C ++ ) - libtheora.a (v.1.1.1) से लिंक लक्ष्य: (डीकोड) खेलने में सक्षम होने के लिए एक एसडीएल 2 एप्लिकेशन में ओग थियोरा वीडियो। मैं एफएफएमपीईजी लाइब्रेरी का इस्तेमाल कर सकता हूं। लेकिन लाइसेंस के मुद्दे हैं क्योंकि वे एमपीईजी ... आदि ... का उपयोग करते हैं, इसलिए मैंने "पेटेंट मुक्त" होने के बाद से ओग थियोरा पुस्तकालय का चयन किया है। ( मैं एक बहुत सरल एसडीएल 2 + के लिए वेब में खोज रहा हूं। ओग थियोरा सी ++ में वीडियो गेम का उदाहरण, मेरे मामले में, केवल ऑडियो वीडियो को डीकोड करने की आवश्यकता नहीं है, और SDL2 को भेजना (संभवतः एक बनावट ...?) लेकिन मैं कुछ भी संबंधित नहीं पाया। मुझे केवल कुछ "गन्दा" कोड मिल गया, फिर भी, जो काम नहीं करता। कोई भी कोड स्निपेट (कोई भी समाधान / कोई सुझाव / अन्य विचार) साझा कर सकता है? ... मेरे पास अब तक का कोड है ... (इस परीक्षण में, मैं "theoraplay.h" का उपयोग कर रहा हूं - इस समय) - // मेरी परियोजना लिंकेज: -lSDL2 -lSDL2_image...

How to install Intel XDK on ubuntu linux - install_gui.sh is missing -

Can someone give me some information on how to install the current version of Intel XD on Ubuntu Linux 14.04 LTS? The There is a file called install.sh but it requires logic and how should I use it, like no document can be found. thanks You might be able to run install.sh without any argument needed. This will bring a GUI installer.

ruby - How to get a last business day of a month with `business_time` gem -

मुझे business_time मणि का उपयोग करके एक माह का अंतिम दिन प्राप्त करना है। यह कोड कार्य करता है यदि माह का पहला दिन एक व्यावसायिक दिन है। 1.business_day.before (दिनांक.पार्स ("2014-12-01")) लेकिन अगर पहले दिन एक व्यवसायिक दिन नहीं है, तो यह एक दिन पहले की तरह वापस आता है: 1.business_day.before (दिनांक.पार्स ("2014- 11-01 ")) # = & gt; 2014-10-30 (यह 2014-10-31 होना चाहिए) रूबी द्वारा एक माह का अंतिम व्यवसाय दिन कैसे प्राप्त कर सकता हूं? यदि आवश्यक हो तो मैं एक और मणि का उपयोग करूँगा। आपको एक मणि की ज़रूरत नहीं है, वास्तव में की आवश्यकता होती है 'डेफ' अंतिम_बजनेस_डे दिन की तारीख = तारीख। पीआरएसई (तारीख)। एनएक्सटीएमओप लूप दिन = दिन.प्रेव_डे तोड़ने तक दिन का दिन। या दिन। अंतिम दिन अंत Last_business_day '2014-11-01' # = & gt; '2014-11-28' अंतिम_ व्यवसाय_दिन '2014-12-01' # = & gt; '2014-12-31'

Why is 08 or 09 in Python invalid? -

इस सवाल का पहले से ही एक उत्तर है: 7 जवाब 3 जवाब पायथन इंटरप्रिटर में, 08 और 09 अमान्य लगता है उदाहरण: & gt; & gt; & gt; 01 1> gt; & gt; 02 2> gt; & gt; & gt; 03 3> gt; & gt; & gt; 04 4 & gt; & gt; & gt; 05 5> gt; & gt; & gt; 06 6 & gt; & gt; & gt; 07 7> gt; & gt; 08 फ़ाइल "& lt; stdin & gt;", पंक्ति 1 08 ↑ सिंटेक्स एरर: अमान्य टोकन & gt; & gt; & gt; 09 फ़ाइल "& lt; stdin & gt;", रेखा 1 9 ^ सिंटेक्स एरर: अमान्य टोकन जैसा कि आप देख सकते हैं, केवल 08 और 09 काम करने के लिए प्रतीत नहीं होता क्या इन विशेष मूल्यों या कुछ चीजें हैं? एक अग्रणी शून्य के साथ एक संख्या ओक्टल शब्दशः के रूप में व्याख्या की जाती है। तो 8 और 9 अक्तूबर में अमान्य हैं I केवल 0 से 7 अंक मान्य हैं। इंटरप्रेटर में प्रयास करें: & gt; & gt; & gt; 011 9 & gt; & gt; & gt; 012 10 & gt; & gt; & gt; 013 11

Having no luck with data NASM -

अनुभाग। डेटा मैप डीबी 1 अनुभाग। टेक्स्ट प्रारंभ करें: cmp byte [map], 1 je exit jmp start exit : Ret मुझे नसीब पढ़ना डेटा नहीं है I मेरा क्या मतलब है कि मैं द्विआधारी डॉस COM स्वरूप को इकट्ठा करता हूं और जब मैं इसे शुरू करता हूँ तो यह सिर्फ फ्रीज होता है। क्या कोई मुझे बता सकता है कि मैं क्या कर रहा हूं? डॉस कॉम फ़ाइलों को पते पर लोड होने की उम्मीद है 0x100। आपके कोड की शुरुआत में आपको लाइन org 0x100 को शामिल करना चाहिए।

java - org.openqa.selenium.ElementNotVisibleException -

I am trying to test a black box with Selenium with which I am working: Mac OS: Version: 10.9.4 Java. Version: 1.6.0_65 Browser: Firefox Version 32.0.3 Selenium: Version 2.43.0 The page contains a table, each Line has a unique ID that is correctly extracted and stored in string item id , then I try to click on related WebElement and click on it: WebElement anchor = webDriver.findElement (By.id (itemId)); If (anchor! = Null) {anchor.click (); Sleeper.sleep (2); } And I'm getting this exception: WARNING: Error extracting item data org.openqa.selenium.ElementNotVisibleException: element currently not visible Therefore, can not be interacted with I've read some questions about the WebDriverWait and tried the following code: string item id = item.getAttribute ("id"); WebDriverWait Wait = New WebDriverWait (webDriver, 10); Web Element Anchor = wait.until (Expected conditions. By.id (itemId); anchor.click (); Sleeper.sleep (2); // Yes, I kn...

jquery - I have to hit back button more than once to hit the back route in Backbone JS -

Back to backbone JS Press me back button more than once to hit the path. I tried to debug it window.onbeforeunload = function () {"you will lose work."; }; But this function is only asked to refresh ideas, let me know what could be the possible solution for this.

scala - java.lang.ClassNotFoundException: play.core.server.NettyServer when more play libraries are added to build.sbt -

I am new to Scala, SBT and Play, so please take it as a noob quest. I'm making an example to play an application for competition, and started with a responsive-stock app as a template. To expand on my functionality, I need to add security, JDBC connections and more. This template is the original build.sbt file given in - scalaVersion: = "2.11.1" Library Deprecations ++ = Seek (YES, // Place Web Service Module "Comm. TipePack.com" %% "Perfect-Actor"% "2.3.4", "Comm. TipePacka" %% "Akka -slf4j"% "2.3.4", "org.webjars"% "Bootstrap "%" 2.3.1 "," org.webjars "%" float "%" 0.8.0 "," com.typesafe.akka "%%" Akk-testkit "%" 2.3.4 "%" exam ") On this I added "com.typesafe.play"% "anorm_2.11"% "2.4.0 -M1", just after the slf4j dependency in the list and the application no Calculus and...

Android Radial Menu -

As I'm looking for the implementation of a radial menu, can someone help me to start ou? I could not understand to attract a piece of PIE. What can we make it? I saw that similar thing was almost implemented in CyanogenMod years ago . You can find the full history of this work with a link to this code here: Competition CyanogenMod Scherus Code is hosted on GitHub: This feature is available on popular 'pie control' Based application ' Regards, Vlad.

Change ssl version with Net::HTTP and Ruby 1.8.7 -

One of my heritage Ruby apps still uses Ruby 1.8.7 It makes many HTTP requests to third party web services and some of them are on SSL. Those third-party services are leaving SSLV3 as a PLL vulnerability and I want to patch my client to continue connecting with them. There is no way to change the SSL version used in Ruby's standard library net :: HTTP . There is a way to change the version in Ruby's openssl (). Unfortunately, this is not appearing by net :: HTTP (). Do we (Ruby users 1.8.7) are bad? Edit : It seems that the customer is switching to TLSv1 if the server does not support SSLv3 . I have an SSL enabled website behind the NSCX, which is without SSLV3 support, and I have verified that my 1.8.7 client is switching to TLSV1 and the request works if you want to verify yourself Here are a look at: In fact, it seems that the customer is TLSV1 Switching on if the server does not support SSLv3 this In other ways, the client server inside the...

sublimetext3 - Sublime Text 3 and phpunit plugin does not work -

After installing Simplephpunit plugin I found this message: phpunit.xml or phpunit.xml.dist not found Code>. I saw this I also clone the development version, but I still get this message. Can anyone help me with it? This is the contents of my XML file: & lt; Phpunit & gt; & Lt; Testsuites & gt; & Lt; Testsuite & gt; & Lt; Directory Prefix = "test-" suffix = ".php" & gt; ./ phpunit_test / & lt; / Directory & gt; & Lt; / Testsuite & gt; & Lt; / Testsuites & gt; & Lt; / PHPUnit & gt;

node.js - Mongoose - Defining child's ObjectID in another Schema -

There is a similar thread @ However, instead of solving this it goes from another method. The second method or part of my title is. Edit - Ignore this section, I am currently using alternate. The problem now refers to a child's object ID elsewhere. I have the following array: Selection: [{4433d18d31f3775756ac2a70: "542e91aa31f3775756abccda"}, {4433d18d31f3775756ac2a71: "542e916c31f3775756abccd8"}, {4433d18d31f3775756ac2a72: "542e934231f3775756abccdb"}] My schema at this time is as follows: Selection: {& LT; Some & gt;: {type: mongoose.Schema.Types.ObjectId, ref: 'choice'}} place in , there essentially said, "I have a way of don?", Cared is not here " Alternatively, as this Internet does not seem possible after modification, I can have the following schema: Selection: {PID: {type: mongoose.Schema.Types.ObjectId, Ref: 'Competition.CHILD'} Selection: {type: mongoose.Schema.Types .ObjectId, R...

python - How get string selection in wx.html.htmlwindow -

I can not find any method to manage Clopboard from context menu I'm trying with wxpython version 2.8 import wx import wx.lib.iewin class main (wx.frame): def __init __ (self, parent): wx.frame .__ init__ (self, guardian, id, Title, position, size, style) self.html_field = HTMLWINDOW (self.p_html, -1) class HTMLWINDOW (wx.html. HTMLWindow): def __init __ (self, guardian, id): self.ie = wx.lib. Iewin.IEHtmlWindow (self, -1, style) self Def (wx.EVT_CONTEXT_MENU, menu itself) def menu (self, event): self.copied = self.ie.getStringSelection () alternative method but only I can get the word I'm not a complete selection def OnCellClicked (self, cell, x, y, eut): If iStance (cell, wx.html. HTMLWordCell): sel = wx HTML HTML selection () word = cell.ConvertToTest (SEL) Super (MILHILLWINDOWO, itself) .OnCellClicked (cell, X, Y, EUT) import wx.lib. I get this error traceback (most recent call final): Value: _type_ 'v' is not supported File "main.py", l...

android - Progress bar while URL loading in WebView -

I have the code below to show a progress bar loading in the form of URL load in WebWeb. Although the line of code: webView.setWebViewClient (new MyWebViewClient ()); There is an error in : Constructor MyWebViewClient () is undefined What else is needed for this work? WebViewActivity: increases the public class WebViewActivity activity {Private WebView webView; Crate on Public Zero (Bundle Saved Instantstate) {Super. Secret (Saved Instantstate); SetContentView (R.layout.webview); Progress PB = new progress bar (WebViewActivity.This); Webview = (webview) Find VVBIID (Raid WebViv 1); WebView.getSettings () setJavaScriptEnabled (true). WebView.setWebViewClient (new MyWebViewClient (pb)); WebView.loadUrl ("http://www.google.com"); } @Override Public Boolean OnKeyDown (Integer Keycode, KeyEvent Event) {if (event.getAction () == KeyEvent.ACTION_DOWN} {Switch (Keycode) {Case KeyEvent.KEYCODE_BACK: if (webView.canGoBack ()) {webView.goBack (); } Else {finish (); } ...

perl - Type of argument to keys on reference must be unblessed -

I am very new to Perl and I have been given the task of maintaining a webpage. I have found a bug that I do not want to fix The Perl script stops at the following code my @ failedTests = (sort (keys ($ TestResultsData {$ CurrPlatform} {$ currDate} {failtests}))); While the (@failedTests) {... error message is: The type of argument for the key on the reference must be closed without a hareframe or a seraph Can that line of code be rewritten so that it works? $ TestResultsData {$ currPlatform} value {$ currDate} {failtests} There is a blessed Hashref: Key is appreciated by the coward, has refused to operate on Hashref, because it will break the illusion of encapsulation and overloading. (Older versions of Perl will not accept Hashref in all - you must pass it to a proper hash.) Attempt to use Hasharft manually in a hash Do: my @failedtests = sort keys% {$ TestResultsData {$ currPlatform} {$ CurrDate} {failtests}};

ios - SQLite syntax error with Encrypted-Core-Data -

I've been running now for a very long time in a syntax error and I unsure as I do Maybe this is the cause . Debug log is as follows: SQL Debug: Select ecdImages.checkSum, ecdImages.creationDate, ecdImages.filename, ecdImages.height, ecdImages.latitude, ecdImages.locationString, ecdImages.longitude, ecdImages. Fear, ecdImages.photoId, ecdImages.photoLogValues, ecdImages.requiresDeletion, ecdImages.requiresUpload, ecdImages.rotationAngle, ecdImages.scale, ecdImages.source, ecdImages.timestamp, ecdImages.title, ecdImages.transform, ecdImages.width, ecdImages.x, ecdImages.y, ecdImages.book__objectid, where ecdImages.page__objectid ecdImages ecdImages .__ ObjectId =?; The statement could not: close "orders" as a syntax error Order type integer is 16 years old and I'm for your reference, I use currently encrypted core data Found on GitHub in Any ideas? said by CL in the comments as , I was using a reserved keyword. Please refer to.

.net - How can DebugDiag analyse a dump file without having matching debugging dlls -

I'm having an error while trying to analyze a dump file. 0: 000> ! The version of threads SOS does not match the version of the CDL that you are debugging. Please load the matching version of SOS for the version of CLB of DOBID. CLR Version: 4.0.30319.1022 SOS Version: 4.0.30319.34011 Failed to load data access, DLL, 0x80004005 Verify that 1) you have recently created debugger (6.2.14 or newer) 2) file mscordacwks.dll The version of Clr.dll that matches your version is on the directory or symbol path 3) Or, if you are debugging a dump file, verify that the file mscordacwks_ & lt; Arch & gt; _ & Lt; Arch & gt; _ & Lt; Version & gt; Dll is on your icon path 4) Dump file is debugging you on supported cross-platform architecture. For example, an ARM dump file should be debuged on an X86 or ARM machine; An AMD64 dump file should be debuged on an AMD64 machine. You can also run the debugger command. To control Cordll's debugger load, mscordacwks.dll....

php - Laravel selecting data with multiple where clauses and returning any pivot data -

I have a relationship with my app where an organization can have many users and many users create multiple organizations in my organization This may look like, organization. Php Public function users () {return $ this-> Affiliate ToMany ('Users') - & gt; WithPivot ('is_admin'); } User.php Public function organizations () {$ this- & gt; Affiliation organization (organization)); } What do I want to do, a query is run in which there is multiple where the clause and then return the row data and any pivot data. For one where I will do the following, $ org = Organization :: Search (1); $ orgUsers = $ Org- & gt; User () ; I do not understand that if I also need a user, how many crowds would I use? Assume that you want to add wheree () to users, Something like this (user is loading anxious) $ constraints = ['fname' = & gt; 'John', 'Laname' = & gt; 'the deer']; $ Org = (= 'user' ...

multithreading - Can I use int in multithreaded C++ safely? -

I have the following code, is there anything that will make it non-threadsof? Class runner {public: volatile int exitFlag; // A runner built in thread () {exitFlag = 0; } // It does not matter when running in thread B void threadFunc () {// when the change is taking place here (exitFlag == 0) {// ... stuff (not using exitFlag)}} / Call it / thread with a zero sign () {exitFlag = 1; // only a bit change; }}; Let me create a runner object and start it in another thread by threadFunc and after some time call signalThread I was told from the first thread that reaching the same variable in various threads (at least writing them) can be born to read the garbage value. But obviously, in the above code (only one bit has been changed) does not make any difference. Apart from this, the order of reading / writing does not matter. unstable code to share the variable between the atom or synchronization Does not offer a reasonable guarantee. The lack of atom is not likely to ...

javascript - Is it necessary to create all combination a separately view in CouchDB -

मेरे पास CouchDB संग्रहीत में निम्नलिखित दस्तावेज हैं: {"_id": "1 "," _rev ":" 1-e3ff3eb51ccf90e0446ef086fcc6a06c "," sub_name ":" A01 "," प्रकार ":" टेस्ट "," नाम ":" ए "," pos ": 828288} {" _id ":" 2 " "_rev": "1-e3ff3eb51ccf90e0446ef086fcc6a06c", "sub_name": "ए02", "टाइप": "टेस्ट", "नाम": "ए", "पॉज़": 828288} {"_id": "3" "_": "1-ef83655c51f64daa4c074fed9beb8234", "sub_name": "B01", "type": "test", "name": "b", "pos": 171878} {"_id": "4", " _rev ":" 1-ef83655c51f64daa4c074fed9beb8234 "," sub_name ":" B02 "," type ":" test "," name ":" b "," pos ...

EXCEL VBA : How to validate value with isString or isNumeric? -

Here my code is given: String like slow m, n long time Until n = InputBox ("Enter the amount of sale:") If & n; 500 or not & gt; 5000 Then ActiveCell.Value = n ActiveCell.Interior.Color = RGB (255, 0, 0) M = InputBox ("cause why increase / decreased?") ActiveCell.Offset (0, 1) .Value = I ActiveCell.Offset 1, 0). Choose Else Active Seal. Value = enactivel.offetts (1, 0). If finished, choose I was finding out how the input is valid when the input string is indicative of the integer and will ask? Thanks in advance for the reply. code: as a dim m string, string In the form, tryAgain as long as sale: n = InputBox ("Enter the sales amount:") If not, numeric (N) then "MSBBC" entry should be a number! " GoTo TryAgain End if the sale = CLNG (N) if sale & lt; 500 or Sale & gt; 5000 Then ActiveCell.Value = Sales ActiveCell.Interior.Color = RGB (255, 0, 0) M = Input box ("cause why increase / decreased?") Acti...

javascript - Refresh data originally passed into modalInstrance in AngularJS -

angular - using UI bootstrap I am passing data in a modal instrument like the below model In, users have the ability to create new items. On the Save button press, a new item is sent to the server. I need the ability to refresh the model instance with updated data from $ scope.items. I note, when saving the modal does not stop, so I can not open it again. Any help would be greatly appreciated. $ scope.items = ['item1', 'item2', 'item3']; $ Scope.open = function (size) {var modalInstance = $ modal.open ({templateUrl: 'myModalContent.html', Controller: 'ModalInstanceCtrl', solve: {item: function () {return $ scope.items;} }}); ModalInstance.result.then (function () {// Post Update $ scope.items // Get fresh $ scope.items from server // Notify modal of updated items}, function () {}); }; }); You try to create a scope for your $ modalInstance $ scope : var modalInstance = $ modal.open ({templateUrl: 'myModalContent.html', ...

RSpec + Capybara: How do I test a Bootstrap progress bar -

I'm testing a page that has the bootstrap progress bar using RSPC. How can I test various Aria features in Div? & lt; Div class = "progress-time progress-time-success" role = "progress bar" aria-valuenow = "40" aria-value = "0" area-valuemax = "100" style = "width: 40%" & gt; ; & Lt; / Div & gt; I appreciate your help. Thank you! You get the attribute value of an element using the [] method You can. For example: find ('div.progress-bar') ['aria-valuenow'] # = & gt; Search for "40" ('div.progress-bar') ['aria-valuemax'] # = & gt; "100" You can test values ​​by doing this: Hope ('div.progress-bar') ['aria-valuenow 'Eq' ('100') However eq ('40 ') is expected (' div.progress-bar ') [' aria-valuemax ']). , Which will not use Capebara's built-in waiting methods If you ...

PHP - exec() method not executing -

मुझे निम्न PHP कोड चलने में समस्या आ रही है: Get_Words_And_Display.php: & lt;? Php की आवश्यकता है ('database.php'); $ Word_w = $ _POST ['शब्द']; $ Word_def = $ _POST ['def']; $ Word_cat = substr ($ word_w, 0, 1); $ SQLQueryIns = "सभी-वर्ड्स (श्रेणी, शब्द, परिभाषा) मूल्यों में शामिल करें ('$ word_cat', '$ word_w', '$ word_def')"; $ MySQL_db- & gt; कार्यकारी ($ SQLQueryIns); // PDO ऑब्जेक्ट $ MySQL_db $ SQLQueryGet = "SELECT * all_words से" को सौंपा गया है; $ SQLGet = $ MySQL_db- & gt; क्वेरी ($ SQLQueryGet); / * प्रत्येक मान को पूर्वनिर्धारित * /? & Gt; का उपयोग करके तालिका में प्रदर्शित किया जाता है। मुझे जो आवेदन करना है वह है: 1) उपयोगकर्ता Create_Word.php 2) Create_Word.php get_words_and_Display.php 3) Get_Words_And_Display.php मूल्यों की प्रक्रिया करता है और मूल्यों को प्रदर्शित करता है हालांकि Create_Word.php प्रदर्शित नहीं किया जाता है (कोई त्रुटि नहीं है)। म...

Grails, Grails RabbitMQ plugin, Java ,Spring AMQP - Multiple clients -

मैंने सरल Grails REST वेब सेवा विकसित की है जो Grails RabbitMQ प्लगइन का उपयोग करती है और कतार में संदेश भेजती है। Grails - Config.groovy क्यूज = {विनिमय नाम: 'my.topic', प्रकार: विषय, टिकाऊ: गलत, {foo टिकाऊ: सही, बाइंडिंग: मेरे जावा डेस्कटॉप ऐप पर मैं स्प्रिंग एएमक्यूपी का उपयोग करके उस संदेश को सुनने की कोशिश करता हूं। मुख्य जावा। सार्वजनिक स्थिर शून्य मुख्य (स्ट्रिंग [] आर्ग्स) {CachingConnectionFactory सीएफ = नया कैशिंग कनेक्शन Factory ("स्थानीयहोस्ट"); cf.setUsername ( "अतिथि"); cf.setPassword ( "अतिथि"); RabbitAdmin व्यवस्थापक = नए RabbitAdmin (सीएफ); SimpleMessageListenerContainer कंटेनर = नया SimpleMessageListenerContainer (सीएफ); ऑब्जेक्ट श्रोता = नया ऑब्जेक्ट () {सार्वजनिक शून्य मैसेज (स्ट्रिंग फू) {System.out.println (foo); }}; MessageListenerAdapter एडाप्टर = नया MessageListenerAdapter (श्रोता); container.setMessageListener (अनुकूलक); container.setQueueNames ( "foo"); container.start (); } जब मैं एक से ...

c# - Can't scroll like a phone when over labels -

Then I was using code from this link, But I ran into an issue, in that form if the user clicks on a label and tries to scroll, then he will not go ahead so I set an event on the labels using the same method lbl.MouseDown + = New MouseEventHandler (This Q & A Panilmouse Daun); Lbl.MouseMove + = New MouseEventHandler (This is the Q & A: PanelMouseMove); With this, when you click on a label, it scrolls to super fast, for this to adjust, I tried to make a new method for mouse move, but +5 And changed the +1 to +1 and -1 It slowed down, but there is not enough space in it, so I can not go slower than 1 or 1. I think the issue relates to the place that it has been sent to label, not the panel, but it actually thinks a way to solve it. I got the answer after many searches. When using code from a link, I use e.Location with PointToClient (cursor. So it looks like this. Point mouseDownpoint; Private Zero InnerNepinalMouseDown (Object Sender, Mouse Eve...

HAProxy and Mysql Cluster Topology -

I have installed mysql cluster 2 data nodes, 2 sqlnode and a management server on different hosts. Apart from this I have 3 different app instances. Now I want to set up Haparoxi in front of the MyScl Cluster, but it is not certain about topology. I searched on google but got very confused because most examples use additional components such as gallery cluster etc. Should I install a separate host or HAPACC on a HAProx with an App Instestes or Ascollnode on the same host? I have read that each one has professional and opposition about the delay being introduced by them but I wonder which one is more acceptable and will use it? Or any reference or tutorial on this? (Apps are running in SPO, the way Santos is running on 6 32bit)

windows - How catch batch file errors in java -

इस सवाल का पहले से ही एक उत्तर है: 4 जवाब सवाल स्वयं व्याख्यात्मक है मैं डेस्कटॉप अनुप्रयोग पर काम कर रहा हूँ जो बैच फ़ाइलों को क्रियान्वित करता है ईमानदारी से मैं बैच फ़ाइलों को प्रकृति को नहीं जानता, लेकिन बैच फ़ाइल को समझने के तरीके के बारे में जानने के लिए मैंने इंटरनेट पर खोज की। अगर कोई पुस्तकालय नहीं है तो बैच फ़ाइल की समाप्ति के लिए एक कमांड लाइन जोड़ना और JVM को झंडा देना संभव है? शायद हम बैच फ़ाइल से एक कमांड निष्पादित कर सकते हैं जो जावा एप्लिकेशन में श्रोता को आमंत्रित करता है? रिटर्न कोड की जांच करें बैच फ़ाइल। अगर% ERRORLEVEL% NEQ 0 (आरईई त्रुटि को संबोधित करने के लिए यहां कुछ करता है)

ruby on rails - How to show uploaded photos in the view -

I am using the carrier's gem and I am trying to upload it to the controller so that all photos are uploaded. (In the photo table inside) by using the box version in the scene. I think that only the selected users are able to show the photo, but I want to show all the uploads. Photo Controller: DEF New @ photo = Photo. Make a new end def @ photo = photo.create (param [: photos]) @photo.user = current_user if @photo. Save flash [: notice] = "photos successfully created." Redirect_to: Backere render: Action => Manipulate the 'new' end-end def size (width, height, gravity = 'center')! Do Img | Do img.combine_options | Cmd | Cmd.resize "# {width}" if img [: width] 'Edit' end-end DF deleted @ photo = photo. Afid (Param [: id]) @photo diestore flash [: notice] = "The photo was successfully destroyed." Redirect_to: back end def Avatar if current_user.update_attribute (: avatar_id, params [: id]) Flash [: notice] = "Suc...

c# - XML serialize base class without knowing derived class -

I know that a XmlSerializer throws an exception if the type passed does not match the type Since then the serializer was created My question is: Is it possible to serial the base type without knowing the derivative type? Consider the following scenario: The following classes are in a top-level domain and there is no dependency : Public Class Serializer {Private Static String Serialize (base basedata) {var serializer = New XML serializer (typefile); Var sb = new stringbilder (); (Var author = XmlWriter.Create (sb)) using {serializer.Serialize (author, bassadata); } Return sb.ToString (); } Private static string Deserialize (...) {...}} Public class base {public string name {get; Set; }} The following derivative classes have additional dependencies on things like UI components, structure, etc. (and more on this later): [Export (Typ (IMyComponent)] Public category was created: Base, IMyComponent, INotifyPropertyChanged {public new string name {get {return base.Name; ...

java - there are three a user clicks on certain JButtons named red, blue, pink and one Jlabel -

Three users click on a user named Red, Blue, Pink, and a Jellybell on some pockets. Add the ActionListener for the button like if the button, the foreground color of the label will change accordingly public Zero verb (verb event e) {// if red is your jbutton (e.getname) Equals ("red")) {// change red color for red color} and if (ed. N.name (). Equals ("blue")) {// change lbl color blue}}

java - Deploying play framework could not find or load main class -

I am preparing for deployment using the district command in Windows 7. (Play 2.0.4) Zip is successful but when I'm trying to start the application with this command: java -Dhttp.port = 9001-cp "e: \ deploy \ Test-1.0-SNAPSHOT \ lib \ *" play.core.server.NettyServer The console displays this error: Error: Could not get or load main class E: \ deploy \ test-1.0-SNAPSHOT \ lib \ ch.qos.logback.logback-core-logback-core-1.0.0.jar I have checked that this jar is played by the Play Framework ... c: \ Play \ play-2.0.4 \ repository \ cache \ ch.qos.logback \ By I get another error if I use the step command: [error] {file: / c: / test /} exam / *: Step: java.io.IOException: The program "chmod" can not be run: CreateProcess error = 2, the system can not be found, the specified file I'm not sure but the original problem Will be related to. the magic ; I command ; after * Finally: java-Dhttp.port = 9001-cp "e: \...

jQuery search for child element, but not with certain div -

I want to stop looking for a specific child element after facing any other element. . DontSearchWithin ("nothere") find $ ("parent") ("children") .; Actually I want to select the elements of all children, but there are no elements of children who are within a specific diva. is an example I want to select the span inside the "non-no" element. & lt; Div id = "parent" & gt; & Lt; Span & gt; FIND ME & lt; / Span & gt; & Lt; Span & gt; FIND ME & lt; / Span & gt; & Lt; Span & gt; FIND ME & lt; / Span & gt; & Lt; Span & gt; FIND ME & lt; / Span & gt; & Lt; Div id = "no-here" & gt; & Lt; Period & gt; Ignore & lt; / Span & gt; & Lt; Period & gt; Ignore & lt; / Span & gt; & Lt; Period & gt; Ignore & lt; / Span & gt; & Lt; / Div & gt; Apart from this, there may be more child elements in it a...

xcode - Create a socket in Swift -

I am trying to write a simple echo server faster I have found examples or are either. I failed in many things, I'll start from the top I high-level functions such as CFSocketCreate using could not manage to make a simple socket This is what I Finished: Class Ecorever: NSObject, NSSTrim Delegate {Private Server Server Socket: CFS ocket Rough? Func start () {self.serverSocket = CFSocketCreate (kCFAllocatorDefault, AF_INET, SOCK_STREAM, 0, 2, and self.acceptConnection, NSNull ())} func Accepted connection (socket: CFSocketRef, type: CFSocketCallBackType, address: CFDataRef, data Unsecured Pointer & lt; null & gt; info: unsafeMutablePointer & lt; zero & gt;) {// accept connection and stuff later}} I'm doing xcode for the new / objectivec / fast and I had a hard time coming to an error message to understand the above code just leave me EchoServer.swift: 31: 93: '(CFSocketRef, type Do: CFSo cketCallBackType, address: Am CFDataRef, data: UnsafePoin...

All Requests to Youtube Analytics API via Google PHP Library Results in 400 Bad Request -

I am able to successfully request a YouTube Analytics API via API Explorer. My code is trying to use the Google PHP client library, specifically the Google_Service_YouTubeAnalytics class. Unfortunately, there is no document on this class. I am setting the ID and identity authentication on the client. I fully believe that it is working correctly, because if I do something wrong to private key that I know wrong, then I get it: {"code" : 400, "error": "Error refreshing OAuth2 token: message: '{\ n \" error \ ": \" invalid_grant \ "\ n}'"} But when I insert the right private key, I get the following response: {"code": 400, "error": "https: / www.googleapis.com \ / youtube Error getting / analytics / v1 "\ / Reports? Id = channel% 3D% 3DCHANNEL_ID and start date = 2014-09-01 and end date = 2014-09-05 and metrics = visible% 2 key: (400) Invalid query. The queries did not follow the expectat...

Java Client/Server SSL Socket Chat -

Ok guys, so I created a Java chat using TCP client / server socket. I am making the server, and then I connect customers to the server so that they can communicate with each other through the server! Code: Server: Public ServerAct () Exception {ServerSocket soc = New ServerSet (5217); While (true) {socket CSOC = society.exe (); // and then code to handle the messages, we do not need it}} and the customer: server soft = new socket (" 127.0.0.1 ", 5217); Thread t = new thread (this); T.start (); // I have omitted many parts of the code, but you know, I focus on the part of the problem connection! So, I want to use SSL protection (so I see changes in Wirehaar). I have used OpenSSL (this is necessary for my accessory) to create Root CA and Device Certificate. I put files on Netbeans in SRT folder and copied the code to two new sections, SSL servers and SSLClient, and Ssl part! Therefore: public SSL server (exception) {SSLContext sslContext = ???? Want to add / ...

algorithm - Sum of a number with any k elements in Array -

Design an algorithm, that a set of n integers and other integer x determines that there exists Is or not Kashmir (n> k> 2) The element in S. whose sum is exactly x. Please give your algorithm its time to run I am preparing for an interview, and I have come into this algorithm. I have solved the problems where the Kashmir problem has been specified. Like 2 or 3 But I can not find any answer where I can solve for any Kashmir. I tried to resolve it using dynamic programming but did not get the result. Nobody can help me on this. you int array CTT size X , then go through the set, and mark the reachable digits -1 are all set in element except for zero, which is set to zero. Repeat this process for each element i on cnt for every element of s Non-negative, check the element cnt. [I + si] (if it's within range of array). If so, set it to cnt [si + i] = max (cnt [i] +1, cnt [si + i]) . Once you all go through the S element, check cnt [x] . If it ...

git - What are references that are not tags or branch heads? -

जब मैं git ls-remote करता हूं मुझे कुछ ऐसा मिलता है: 679ba3cdb7201763c0a243e0169a7f8fd210b5b1 प्रमुख 045b31588f934722cd9df1570987ed84b6e9b070 refs / सिर / सुविधा / आद्य संस्करण अद्यतन 7b278f052ab47c49a6c1ac9bd12d05b72a4af584 refs / सिर / IML 679ba3cdb7201763c0a243e0169a7f8fd210b5b1 refs / सिर / मास्टर 52dc74d4b4775d7e24534b87908fb5efcd6d3118 refs / पुल अनुरोध / 453f675541cd12e01cb05a7f8a63fadfb26e62fa refs से 14 / / पुल अनुरोध / 14 / मर्ज मुझे पता है कि refs / pull-requests / 14 / merge की तरह पिछले दो प्रविष्टियां के लिए हैं - वे हमारे द्वारा बनाई गई हैं पुर्न अनुरोधों को प्रबंधित करने के लिए केंद्रीय रेपो (स्लाव) (मैं उन्हें संशोधित करने का कोई इरादा नहीं है, मैं सिर्फ उत्सुक हूँ और हुड के नीचे देखना चाहता हूं, मुख्यतः जीआईटी को रास्ते में थोड़ा बेहतर समझना) लेकिन मुझे समझ में नहीं आता कि वे क्या हैं । वे शाखाओं या टैग नहीं दिख रहे हैं ( - head - tags को कमांड को छिपाने के लिए जोड़ते हैं), और उन्हें प्राप्त नहीं करता है। वे क्या हैं? मैं उन्हें स्थानीय रूप से ...

In Java 8, can the method reference part of a call always be parenthesized? -

मेरे पास एक सही जावा विधि कॉल है, जैसे कि fg (5) जावा 8 अब विधि संदर्भ की अनुमति देता है, इसलिए ज्यादातर मामलों में एक (f :: g) (5) प्रश्न : क्या यह हमेशा भी संभव है ऐसे मामलों में जहां f :: g अतिभारित है, या दो चरण प्रक्रिया से हस्तक्षेप कर सकते हैं? प्रेरणा: मैं कंपाइलर-जैसी कोड लिख रहा हूं, यही वजह है कि मुझे इन सूटलेट्स को समझने की ज़रूरत है, यह ऐसा होगा यदि अधिभार निर्धारण विधि विधि के स्तर पर होना चाहिए। । मुझे पता है कि कॉल में विधि संदर्भ को कोष्ठक करने के लिए एक आवश्यक सॉफ़्टवेयर इंजीनियरिंग अभ्यास नहीं है। नहीं। हालांकि, मुझे लगता है कि आप इस सुविधा के बारे में भ्रमित हैं। उपरोक्त में f.g की कथन विधि संदर्भ नहीं है; यह एक अभिव्यक्ति भी नहीं है एक विधि संदर्भ एक अभिव्यक्ति है जो Foo :: bar जैसा दिखता है और इसे एक कार्यात्मक इंटरफ़ेस प्रकार में कनवर्ट किया जा सकता है।

python - pandas DataFrame add a new column and fillna -

I am trying to add a column to a pdf data frame, such as: Df = 'Pd.DataFrame') ['A'] = PD. Print (DF) df ['two'] = pd.Series ({'0': 4, '2': 6}) Print (DF) This yield: one two 1 4 NaN 2 6 6 However, I could have the result, A two 0 NaN 4 1 4 NaN 2 6 6 How do you do this? You can join want to do this: df = pd.DataFrame () df ['one'] = pd.Series ({'1': 4, '2': 6}) df.join (Pd.Series ({'0' : 4, '2': 6}, name = 'two'), how = 'outer') The result of A two nan 4 1 4 nan 2 6 6

javascript - Optimize AngularJS ngHide attribute -

& lt; span ng-hide = "(getStatusIcon (निष्क्रिय.currentStatus.code) .statusDesc) == ' समाप्त हो गई '() (getStatusIcon (inactive.currentStatus.code) .statusDesc) ==' अस्वीकृत '|| (getStatusIcon (inactive.currentStatus.code) .statusDesc) ==' मना कर दिया '"& gt; पीओ # [[असक्रिय.poNumber]] & lt; / span & gt; मैं कोड को अनुकूलित करना चाहूंगा यदि GetStatusIcon (inactive.currentStatus.code) .statusDesc है (समाप्त हो गया है, अस्वीकार कर दिया गया है) हम स्पैन टैग छुपा रहे हैं अभी हम फ़ंक्शन को 3 बार बुला रहे हैं GetStatusIcon (inactive.currentStatus.code) को चेक करने का एक तरीका है। StatusDesc (समाप्त हो गया, अस्वीकार कर दिया गया) फ़ंक्शन केवल एक बार कॉल कर रहा है। आप एनजी-इनइट का इस्तेमाल केवल फ़ंक्शन को कॉल करने के लिए कर सकते हैं: & lt; span ng-init = "statusDesc = getStatusIcon (inactive.currentStatus.code) .statusDesc" ng-hide = "(statusDesc) == 'समय सीमा समाप्त' || (statusDesc) == ' अस्वीकृत ...

jquery - Change form autofill background yellow color -

I got this topic I have only one problem but the solution does not work for any reason On the website instead of i Yello background I would like a trasparent. I changed $ to jQuery but nothing has changed Thank you in advance. Here's a solution to your question

c - Allocating a pointer by passing it through two functions -

What am I doing wrong here? Am I assigning memory to the original charPtr or something else? Why can I read the value of func2 inside charPtr , but main ( charPtr is NULL in the main)? #include & lt; Stdlib.h & gt; # Include & lt; Stdio.h & gt; Zero func2 (char * charPtr) {charPtr = (four *) molk (size (four)); * CharPtr = 'c'; Printf ("func2:% c \ n", * charPtr); } Zero func1 (four ** charDoublePointer) {// * charDoublePointer = (four *) malloc (sizeof (char)); Func2 (* charDoublePointer); } Int main (int argsc, char * argv []) {char * charPtr = NULL; Func1 (& amp; charPtr); Printf ("% c \ n", * charPtr); } You are losing a level indirection func2 Take the TI to four ** like func1 . When you type: void func2 (char * charPtr) {charPtr = (four *) malloc (sizeof (char)); * CharPtr = 'c'; Printf ("func2:% c \ n", * charPtr); } You are just assigning local variable charPtr , which has no eff...

python - How to debug an import statement changing behavior -

I have a script that I was trying to add to signal handler for ctr-c, something before exiting To the final handling. It's own, it works fine, but as soon as I try in my program, it does not work. Adding or removing an import varies behavior. Without P4 API imports, it expects I hope. If I import the P4 API, the CTR-C asks to exit or bypass my handler, and I'm not sure why, Import sign import time import sys # - Commented on this, things work #import P4API def run_program (): While this is true: time.sleep (1) print ("a") def exit_gracefully (Signum, Frame): # Not to mention the original signal handler signal, otherwise the bad things will be # in raw_input when CTRL + C is pressed, and our signal Try Andlr no entrant again signal.signal (.SIGINT, original_sigint): If raw_input ( "? \ Nreally leave (y / n) & gt;") .lower () startswith ( 'y') :. Sys.exit (1) except the KeyboardInterrupt: print ("OK OK signal.SIGINT # store origin...

javascript - How to access the events in iCalendar in Swift? -

मैं स्विफ्ट सीख रहा हूं और iCalendar के माध्यम से EventKit । उद्देश्य- C में, यह इस तरह काम करता है: [eventStore requestAccessToEntityType: EKEntityTypeEvent पूरा: ^ (BOOL मंजूर, NSError * त्रुटि) {}] ; दस्तावेज़ से स्विफ्ट में: eventStore.requestAccessToEntityType (इकाई प्रकार: EKEntityType>, ** पूर्णता: EKEventStoreRequestAccessCompletionHandler! ) ** क्या है " पूरा: EKEventStoreRequestAccessCompletionHandler " और मुझे यहाँ क्या रखा जाना चाहिए? ⌘- पर क्लिक करें EKEventStoreRequestAccessCompletionHandler (या कोई अज्ञात प्रकार), और Xcode इसकी परिभाषा के लिए कूद जाएगा: टाइपलीज़ EKEventStoreRequestAccessCompletionHandler = (बूल, एनएसईआरआर!) - & gt; शून्य

Ruby separating an array of strings by checking whether or not the object inherits from a certain class -

I have a string in which I read a file from x I have an empty array y some string objects are integer how can I separate the integers with strings, special forms I'm still trying to call to_a with x.each do | S | If s.to_i.is_a? (Integer) y & lt; & Lt; But it just changes everything in an integer and puts it in y , there is a way to see that an object is actually in the integer class ? Add sample input / output x = ["this", "is", "one", "random" "", "Key", "ka", "number", "111113087403957304739703975", "how", "can", "me", "read", "combination", "ka", "text", " And "," a "", "in this."] Y = [111113087403957304739703975] x.each do | s begin the integer Logic Argument arguments yy If a string is applied that does not parse as integer , Then...

c++ - Shadow map stuck at 1 -

I am following the shadow tutorial and given depth in the combine quad on the screen, I see depth values ​​in depth texture Can i The problem is that when I am sampled with this depth texture, then I get only one value. In this way I set up a depth texture FBO; The size of the texture is set to the size of the window, I'm not sure that this is part of the problem, but if I try to see the dimensions of the depth and try to see it, I look at the fourth part of a corner of the scene. I thought textures are always used from [0,1]? glagfire buffers (1, and framebuffer name); GlobeFramebuffer (GLFFAMFFER, framebuffernname); Glenn Texture (1, and Display Fixtures); Globind Extraction (GL_EditEdda, Renderettecht); GlTexImage2D (GL_TEXTURE_2D, 0, GL_DEPTH_COMPONENT, FBWITH, FBHEIT, 0, GL_DPTHG, GL_Float, 0); GlTexParameteri (GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); GltexPamerMarty (GL_EducationEd.D., GL_WhartWar_User, GLCLAAPMOGOGEG); GlTexParameteri (GL_TEXTURE_2D, GL_...

string - Stick delineated between array elegantly -

At any time, I need to string from the list that has some kind of depiction, I have something like this string output = ""; For (int i = 0; i & lt; array.label; i ++) output + = array [i] + ","; Return output; But it always adds a comma to the end where I do not want this. To avoid this I have to do string output = ""; For (int i = 0; i Is there any more great way to achieve this goal? is an option: string output = array [0] ; For (int i = 1; i & lt; array.label; i ++) output + = "," + array [i]; Return output;

How to have Jekyll-Bootstrap not put "index.html" in the navigation -

I am a happy user, although the index.md template has been compiled Index.html . It is expected, but unwanted behavior for me. When the navigation link on the homepage uses index.html on this anchor, I can get around this using a nginx redirect, but a link to my site I do not want to be "fixing" using the 301 redirect. I would like to make it the right link in the first place. Then it should be clear. I do not want to link Jacob to index.html but link to / instead. You enter HOME_PATH in _includes / jb / setup By default, this is {% HOME_PATH = assigns} "" / "%} .

c# - How do you create your own DataType? -

I would like to create my own DataType named positiveInteger I know what you are thinking? You are thinking that I should use uint but uint has 0 and I want only positive numbers . Now you can tell me to create a class named positiveInteger . Yes, I can make a class called positiveInteger , but I do not know how to implement this class that this new datatyuse only accepts positive integer values? Example can be an example: Public Structure PositiveInteger : IEquatable & lt; PositiveInteger & gt; IComparable & lt; PositiveInteger & gt; {Public-positive integer (UIT value) {if (value ; = 0) leave the new argument with the exception exception (); _value = value; } Public UIT Value {Received {Return _value == 0? 1: _value; }} Private Readonly UIT _ Value; Public stable built-in operator-positive integer (UIT value) {returns new positive integer; } Public stable built-in operator UIT (positive etaser value) {return value. Value; } Public Stati...