Search Results

Search found 5682 results on 228 pages for 'lord of scripts'.

Page 165/228 | < Previous Page | 161 162 163 164 165 166 167 168 169 170 171 172  | Next Page >

  • New to Android I want to know more about it

    - by Lavan
    Well,Hello Everyone.I'am just 14 years old.I want to be a part of Android's Development. But were do I start.What should I learn? What are necessary Qualification to be a Part of Android's Development. Things what I know Basic PHP, HTML, PhotoShop, Video Editing, Basic Security and Fraud related matters, Some Microsoft Office Tools, Maya(Modelling only), Web Development, Dreamweaver, Blogging and Pawno (For Game Scripts..C Based Language) I hope that's all. I do things (for programming)without knowing about the basics it has. I feel difficult to understand the guides in android.com . I want a Step by Step guide. Thank you, Lavan

    Read the article

  • Writing Ruby Libraries - hiding methods from outside the module

    - by JP
    Hi all, I'm writing a Ruby library which has a module with a bunch of classes inside it. Many of these classes need to be usable and modifiable by calling scripts, but I don't want (some of) the initializers to be visible/callable: module MyLib class Control def initialize # They can use this end def do_stuff Helper.new('things') end end class Helper # Shouldn't be visible def initialize(what) @what = what end def shout @what end end end c = MyLib::Control.new h = c.do_stuff p h.shout # => "things" # ^ All of this is desired # v This is undesirable p MyLib::Helper.new('!') # => <MyLib::Helper @what='!'> If it's a simple thing, then I'd also appreciate the generated RDoc not even include the .new method for the Helper class either. Any ideas? Thanks for reading!

    Read the article

  • Can you make a python script behave differently when imported than when run directly?

    - by futuraprime
    I often have to write data parsing scripts, and I'd like to be able to run them in two different ways: as a module and as a standalone script. So, for example: def parseData(filename): # data parsing code here return data def HypotheticalCommandLineOnlyHappyMagicFunction(): print json.dumps(parseData(sys.argv[1]), indent=4) the idea here being that in another python script I can call import dataparser and have access to dataParser.parseData in my script, or on the command line I can just run python dataparser.py and it would run my HypotheticalCommandLineOnlyHappyMagicFunction and shunt the data as json to stdout. Is there a way to do this in python?

    Read the article

  • Import Data from Excel Spreadsheet or CVS into MySQL

    - by Kelly Roper
    I have a spreadsheet which really has only one complicated table. I basically convert the spreadsheet to a cvs and use a groovy script to generate the INSERT scripts. However, I cannot do this with a table that has 28 fields with data within some of the fields on the spreadsheet that make importing into the CVS even more complicated. So the fields in the new CVS are not differentiated properly or my script has not accounted for it. Does anyone have any suggestions on a better approach to do this? Thanks.

    Read the article

  • Looking for a new PHP website framework

    - by Glycerine
    I built many a website, and my own 'custom' framework is just a general box of scripts cobbled together with loose ideas. I would love to progress to a framework which allows me to pass it onto the client for freedom. Someone suggested using wordpress but I'm not sure how general this can be. A current site I need to build is a fancy kitchen company, price lists, flash gallery (with backend driven pics) and well designed home. How could I bend the the will of wordpress? Alternatively, does anyone have a suggestion for an alternative. Thanks in advance guys -

    Read the article

  • Running python/ruby script on iPhone?

    - by prosseek
    From the recent news from the Apple, I learned that one has to use C/C++/Objective-C for iPhone App. Accordingly, it's not possible to use MacPython or similar to make iPhone App. But as the python/ruby interpreter itself is written in C, isn't it OK to make python/ruby interpreter for iPhone to run the scripts on iphone? Is this possible? Does Apple support this? Or does someone implemented this? Or, the user should hack to do this?

    Read the article

  • PHP: producing relative date/time from timestamps

    - by KeyStroke
    Hi, I'm basically trying to convert a Unix timestamp (the time() function) to a relative date/time that's both compatible with past and future date. So outputs could be: 2 weeks ago 1 hour and 60 minutes ago 15 minutes and 54 seconds ago after 10 minutes and 15 seconds First I tried to code this, but made a huge unmaintainable function, and then I searched the internet for a couple of hours, yet all I can find are scripts that produce only one part of the time (e.h: "1 hour ago" without the minutes). Do you have a script that already does this? If so, I'd really appreciate if you could share it. Thanks.

    Read the article

  • Comparison question string vs int

    - by Mike
    Can someone explain to me why these comparisons work they way the do. I had a bug in one of my scripts that took me a little bit to work through. I was using read-host and typing a number. It was storing it as a string. Write-Host "(`'2`' -gt 9 ) = " ('2' -gt 9 ) Write-Host "(2 -gt 9 ) = " (2 -gt 9 ) Write-Host "(`'2`' -gt 10 ) = " ('2' -gt 10 ) If you are comparing a string to an Int does it use the Ascii value? If so why does the first one show $false, it should be $true. Then how is it when you chage it to an int of 10 it because $true.

    Read the article

  • Interacts with dialog/whiptail on early boot rcX.d stage?

    - by nm
    Hi buddies, I'm developing on Ubuntu based, actually I got one script in-charged on GUI(console) setup. It runs before another scripts (rcX.d) start. Currently, I installed this script on rc2.d and start earlier than other ones. But when run on real machine, I can't input any keystroke on "dialog --inputbox" or whiptail through shell script. Additionally, It runs well on my Virtual Machine (Virtual Box and Vmware), that's so strange! So, does anybody give some help or point me any clues for overcome this ? Thanks

    Read the article

  • Figuring out the resource a lock in SQL Server 2000 affects

    - by Michael Lang
    I am adding a simple web-interface to show data from a commercial off the shelf (COTS) application. This COTS issues locks on any record the user is actively looking at (whether they intend to edit and update it or not). I have found sp_lock and the Microsoft sp_lock2 scripts and can see the locks, so that's all well and good. However, I cannot figure out how I can tell if a specific record I am about to update has been affected by one of these locks. If I submit the update request and there is in fact a lock, the web-interface will wait indefinitely until the user closes the window in the COTS. How can I either: a) determine before issuing an update that the record has been locked OR b) issue an update that will immediately return with a LOCKED status rather than indefinitely waiting on the COTS user to close their window on that record?

    Read the article

  • Magento data-install script

    - by Vladimir Kerkhoff
    I'm trying to build a data install script that I use to setup a new webstore. This script creates the categories, pages and static blocks and default settings for the specific shop (we use a multistore setup to host the shops). In our dev/staging setup this scripts runs great and all categories are build without any problem. But on our live system this script fails. After some debugging I found the difference is in the Flat catalog usage on the live systems. The problem with creating the category with the flat tables enabled is in getting the parent path information based on the parentId given: $parentCategory = Mage::getModel('catalog/category')->load($parentId); Without flat categories enabled this gives a correct parentCategory, but with flat categories enabled it gives an empty object. Why is this behaviour with flat categories enabled?

    Read the article

  • Is file_get_contents multi line?

    - by Abs
    Hello all, Does file_get_contents maintain line breaks? I thought it did but I have tried this: if($conn){ $tsql = file_get_contents('scripts/CreateTables/SLR05_MATCH_CREATETABLES.sql'); $row = sqlsrv_query($conn, $tsql); print_r(sqlsrv_errors()); } The errors I get is that SQL Server complains that there is incorrect syntax. I get the same errors when I run the SQL Script without any line breaks, which suggests file_get_contents removes them? When I run the script normally (open the file in SQL Server Management Studio) and execute it, it works perfectly. So is there something that I can use that maintains line breaks etc? Or is there another problem here in using queries from a file with the SQL Server PHP Driver from Microsoft? Thanks all for any help

    Read the article

  • javascript location.hash refreshing in IE

    - by aepheus
    I need to modify the hash, remove it after certain processing takes place so that if the user refreshes they do not cause the process to run again. This works fine in FF, but it seems that IE is reloading every time I try to change the hash. I think it is related to other things that are loading on the page, though I am not certain. I have an iframe that loads (related to the process) as well as some scripts that are still being fetched in the parent window. I can't seem to figure out a good way to change the hash after all the loading completes. And, at the same time am not even positive that it is related to the loading. Any ideas on how to solve this?

    Read the article

  • How should I migrate DDL changes from one environment to the next?

    - by Rl
    I make DDL changes using SQL Developer's GUI. Problem is, I need to apply those same changes to the test environment. I'm wondering how others handle this issue. Currently I'm having to manually write ALTER statements to bring the test environment into alignment with the development environment, but this is prone to error (doing the same thing twice). In cases where there's no important data in the test environment I usually just blow everything away, export the DDL scripts from dev and run them from scratch in test. I know there are triggers that can store each DDL change, but this is a heavily shared environment and I would like to avoid that if possible. Maybe I should just write the DDL stuff manually rather than using the GUI?

    Read the article

  • Selenium Webdrivers: Load Page without any resources

    - by Biffy
    I am trying to prevent Javascript from changing the site's source code I'm testing with Selenium. The problem is, I can't just simply turn Javascript off in the Webdriver, because I need it for a test. Here's what I'm doing for the Firefox Webdriver: firefoxProfile.setPreference("permissions.default.image", 2); firefoxProfile.setPreference("permissions.default.script", 2); firefoxProfile.setPreference("permissions.default.stylesheet", 2); firefoxProfile.setPreference("permissions.default.subdocument", 2); I don't allow Firefox to load any Images, Scripts and Stylesheets. How can I do this with the Internet Explorer Webdriver and the Chrome Webdriver? I have not found any similar preferences. Or is there even a more elegant way to stop the webdrivers from loading the site's JS Files after all? Thank you!

    Read the article

  • How can I tell if a SQL Server database is being backed up

    - by Guy
    Is there a way to programmatically determine if a SQL Server backup is currently being performd on a particular database? We have automated database backup scripts for both data and log files, where the databases are backed up nightly and log files are backed up every 15 minutes, 24 hours a day. However, we think that the log file backup job is failing if it runs the same time as the full backup is being run. What I'd like to do is to make a change to my transaction log script to not run a transaction log backup while the full backup is being run. If there a DMV or a system table that I can query and work this out?

    Read the article

  • How to make sure the value is reset in foreach loop in PHP

    - by kwokwai
    Hi all, I was writing a simple PHP page and a few foreach loops were used. Here are the scripts: $arrs = array("a", "b", "c"); foreach ($arrs as $arr) { if(substr($arr,0,1)=="b") { echo "This is b"; } } // ends of first foreach loop and I didn't use ifelse here And when this foreach ends, I wrote another foreach loop in which all the values in the foreach loop was the same as previous foreach. foreach ($arrs as $arr) { if(substr($arr,0,1)=="c") { echo "This is c"; } } I am not sure if it is a good practice to have two foreach loops with same values and keys. Will the values get overwritten in the first foreach loop?

    Read the article

  • SQL Server 2000, how to automate import data from excel

    - by Stan
    Say the source data comes in excel format, below is how I import the data. Converting to csv format via MS Excel Roughly find bad rows/columns by inspecting backup the table that needs to be updated in SQL Query Analyzer truncate the table (may need to drop foreign key constraint as well) import data from the revised csv file in SQL Server Enterprise Manager If there's an error like duplicate columns, I need to check the original csv and remove them I was wondering how to make this procedure more effecient in every step? I have some idea but not complete. For step 2&6, using scripts that can check automatically and print out all error row/column data. So it's easier to remove all errors once. For step 3&5, is there any way to automatically update the table without manually go through the importing steps? Could the community advise, please? Thanks.

    Read the article

  • Recursively disabling CONFIG dependencies on linux kernel builds

    - by Corey Henderson
    When configuring a Linux kernel, I normally start with my distribution's kernel config file. I often want to turn off some entries, but they are sometimes unchangeable because other CONFIG options that depend on it are enabled. I can look up the dependencies manually, which often have dependencies of their own. It can be pretty time consuming to did through them all, especially if you're trying to turn off something like CONFIG_KALLSYMS. Is there a way to specify a CONFIG option you want gone, and have all dependencies automatically selected/disselected as nessisary for you? I looked through all the make options and in the scripts directory, and didn't see anything available for this.

    Read the article

  • Determining Terminal lines/cols via PHP CLI

    - by eFrane
    I know that it is quite easy to figure out a terminal's size parameters via the stty -a command. When using local CLI PHP scripts, there is no problem at all on grabbing that output via system() or so. But I am trying the same thing via a php script started from an ssh command. Sadly, all that stty ever returns is: stty: standard input: Invalid argument. The calling code is: exec('stty -a | head -n 1', $query); echo $query[0]; So the question is: If I can output to the terminal and read input from it (e.g. can fread() from STDIN and fwrite() to STDOUT in PHP, shouldn't stty also have valid STDIN and STDOUT?

    Read the article

  • How do I know if my PHP application is using too much memory?

    - by John
    I'm working on a PHP web application that let's users network with each other, book events, message etc... I launched it a few months ago and at the moment, there's only about 100 users. I set up the application on a VPS with ubuntu 9.10, apache 2, mysql 5 and php 5. I had 360 Mb of RAM, but upgraded to 720 MB a few minutes ago. Lately, my web application has been experiencing outages due to excessive memory usage. From what I can tell in error logs, it seems the server automatically kills apache processes that consume too much memory. As a result, I upgraded memory from 360 MB to 720 MB as a stop-gap measure. So my question is, how do I go about resolving these outage issues? How do I know if my website's need for more memory is due to poor code or if it's part of the website's natural growth? What's the most efficient way to determine which PHP scripts consume the most memory?

    Read the article

  • python [lxml] - cleaning out html tags

    - by sadhu_
    from lxml.html.clean import clean_html, Cleaner def clean(text): try: cleaner = Cleaner(scripts=True, embedded=True, meta=True, page_structure=True, links=True, style=True, remove_tags = ['a', 'li', 'td']) print (len(cleaner.clean_html(text))- len(text)) return cleaner.clean_html(text) except: print 'Error in clean_html' print sys.exc_info() return text I put together the above (ugly) code as my initial forays into python land. I'm trying to use lxml cleaner to clean out a couple of html pages, so in the end i am just left with the text and nothing else - but try as i might, the above doesnt appear to work as such, i'm still left with a substial amount of markup (and it doesnt appear to be broken html), and particularly links, which aren't getting removed, despite the args i use in remove_tags and links=True any idea whats going on, perhaps im barking up the wrong tree with lxml ? i thought this was the way to go with html parsing in python?

    Read the article

  • Visual Studio build and deploy ordering

    - by mthornal
    We have a VS 2010 solution that includes a few class library projects, a SQL Server 2008 database project and a Wix setup project. We are trying to get to a point where the following happens in the order specified: Build the class library projects and the database project Deploy the database project to generate the deploy .sql script Build the Wix setup project. The reason for the desired order is that the setup project requires the deployment .sql scripts as it will use these to generate/update the database on the machine that the msi is run. It seems that there is no way within a Visual Studio solution file to create this type of build/deploy/build order. Is this correct? Thanks

    Read the article

  • ASP.NET MVC 2 project default script files. What do you use?

    - by Andrew Florko
    Many js files are included into Scripts folder by default in ASP.NET MVC 2 Projects. I suppose developers use jquery library nearly every time they program a site, but what about other files? Please, can you tell scenarios and reasons when you: Use Microsoft.Ajax instead of jquery or mix both libraries? Do you use JQuery validation infrastructure instead of asp.net mvc one, or combine them both? Thank you in advance! P.S. there are also diferrent editions of the same file. Do you include different editions depenending on debug/release build?

    Read the article

  • Simple ant build script that supports src/ and test/?

    - by M-x
    Currently I use an IDE for all my builds and unit tests. Now I have a need to use ant. I found a few simple ant build.xml scripts but they didn't support a separate Junit test/ dir. My projects are structured as follows: src/ com/foo/ com/bar/ test/ -- Mirror of src/, with all *Test.java files. com/foo/ com/bar/ lib/ -- All Java libs, including junit 4. How can a construct a small ant script that builds my src/ and test/ Java classes then runs all my JUnit tests?

    Read the article

< Previous Page | 161 162 163 164 165 166 167 168 169 170 171 172  | Next Page >