Daily Archives

Articles indexed Friday May 21 2010

Page 24/114 | < Previous Page | 20 21 22 23 24 25 26 27 28 29 30 31  | Next Page >

  • How to define a owner, group and others through PHP?

    - by Starx
    Whenever we use chmod, we set different authorities to different users types like owner, group, others, all What I dont know is, how do define who is owner, who is group and who are others. Can we use this while implementing login system? What I mean is, by verifying a username, I want to define if the logged in user is owner, a group or others so that I can deny access to file or folder. May be my title does not reflect the question, if someone with rep power finds a better title, please edit it?

    Read the article

  • opening word document contailning macros using textarea

    - by avani-nature
    Hai frnds i am avani here,actually 1.i amhaving one word document which contains macros i wann to open it in textarea.. 2.i am able to open the word document which is not containing macros 3.i am not able to open the document which contains macros 4.i am using below code 5.please do help me anyone i am thinking its some what impossible { //echo $aud; $filename = 'C:/xampp/htdocs/mts/sites/default/files/a.doc'; //echo $filename; if(isset($_REQUEST['Save'])){ $somecontent = stripslashes($_POST['somecontent']); // Let's make sure the file exists and is writable first. if (is_writable($filename)) { // In our example we're opening $filename in append mode. // The file pointer is at the bottom of the file hence // that's where $somecontent will go when we fwrite() it. if (!$handle = fopen($filename, 'w')) { echo "Cannot open file ($filename)"; exit; } // Write $somecontent to our opened file. if (fwrite($handle, $somecontent) === FALSE) { echo "Cannot write to file ($filename)"; exit; } echo "Success, wrote ($somecontent) to file ($filename) - Continue - "; fclose($handle); } else { echo "The file $filename is not writable"; } } else{ // get contents of a file into a string $handle = fopen($filename, "r"); $somecontent = fread($handle, filesize($filename)); $word = new COM("word.application") or die ("Could not initialise MS Word object."); $word-Documents-Open(realpath("$filename")); // Extract content. $somecontent = (string) $word-ActiveDocument-Content; //echo $somecontent; $word-ActiveDocument-Close(false); $word-Quit(); $word = null; unset($word); fclose($handle); } ? Edit file -------- ?

    Read the article

  • Performance Related features for migration from .net 2003 Framework 1.1 to .net 2008 framework 3.5?

    - by KuldipMCA
    I am work on VB.net 2003 Framework 1.1 for last 3.5 years in windows Application. We are currently migrating to VB.net 2008 framework 3.5, but i don't know about the features which related to ADO.net and which is important to performance. I know linq to SQL but our architecture is made in .net 2003 so we should follow this. Any features which is very important to enhance the performance?

    Read the article

  • I need to auto_increment a field in MySQL that is not primary key

    - by behrk2
    Hey everyone, Right now, I have a table whose primary key is an auto_increment field. However, I need to set the primary key as username, date (to ensure that there cannot be a duplicate username with a date). I need the auto_increment field, however, in order to make changes to row information (adding and deleting). What is normally done with this situation? Thanks!

    Read the article

  • Out-of-memory algorithms for addressing large arrays

    - by reve_etrange
    I am trying to deal with a very large dataset. I have k = ~4200 matrices (varying sizes) which must be compared combinatorially, skipping non-unique and self comparisons. Each of k(k-1)/2 comparisons produces a matrix, which must be indexed against its parents (i.e. can find out where it came from). The convenient way to do this is to (triangularly) fill a k-by-k cell array with the result of each comparison. These are ~100 X ~100 matrices, on average. Using single precision floats, it works out to 400 GB overall. I need to 1) generate the cell array or pieces of it without trying to place the whole thing in memory and 2) access its elements (and their elements) in like fashion. My attempts have been inefficient due to reliance on MATLAB's eval() as well as save and clear occurring in loops. for i=1:k [~,m] = size(data{i}); cur_var = ['H' int2str(i)]; %# if i == 1; save('FileName'); end; %# If using a single MAT file and need to create it. eval([cur_var ' = cell(1,k-i);']); for j=i+1:k [~,n] = size(data{j}); eval([cur_var '{i,j} = zeros(m,n,''single'');']); eval([cur_var '{i,j} = compare(data{i},data{j});']); end save(cur_var,cur_var); %# Add '-append' when using a single MAT file. clear(cur_var); end The other thing I have done is to perform the split when mod((i+j-1)/2,max(factor(k(k-1)/2))) == 0. This divides the result into the largest number of same-size pieces, which seems logical. The indexing is a little more complicated, but not too bad because a linear index could be used. Does anyone know/see a better way?

    Read the article

  • Working in a Foreign Country [closed]

    - by iersoy
    How does it look like to be working in a foreign country? can u share your experiences with me? Is MCPD or MCITP certification and TOEFL-IELTS-Cambridge degrees will be enough for working in a foreign country? What needs to be done to find an employer to work in his/her company? EDIT: I live in Turkey,Istanbul and i like to work in one of these countries: USA UK Germany Italy France Sweden Denmark Finland Norway Switzerland Austria Holland Belgium Canada i need to make quick moves about my career and my path nowadays Thanks a lot

    Read the article

  • Regular expression replacing only if contained withing a regular expression match?

    - by Tower
    Hi, I have the following: [list] [*] test [*] test [*] test [/list] and I would like to create a regular expression that turns that into: <ul> <li>test</li> <li>test</li> <li>test</li> </ul> I know regex enough to replace simple tags, but in this case I need to replace li tags only if they are contained inside ul. Is there a way to check that before replacing? I am using JavaScript if that matters.

    Read the article

  • Two new profile in new visual studio 2010.

    - by Jalpesh P. Vadgama
    Visual studio 2010 is a great tool and i have become fan of visual studio 2010. I have found two new code profile in visual studio 2010. Web Development Profile Web Development Code Optimized Profile. Web Development profile will hide the top bar which contains the client object and and event dropdowns. So it will have more spaces. Another one web development code optimized which will hide all the things except main windows. It will hide Toolbox,CSS properties and all other things so you will have more spaces to play with your html. So as a web developer you can use this two great new profile as per your convenience when you only want to play with your html then use webdevelopement code  optimized profile and another interesting thing is that you don’t have to reset your settings you can also just do with Tools->Settings menu like below. This will swap different profile like below. Hope this will help you.. Technorati Tags: Visual Studio 2010,ASP.NET 4.0

    Read the article

  • Win7 UAC tokens

    - by Talc
    It is known that under win7 UAC you receive 2 tokens when you logon to the system: std user token and admin token. If I disable UAC, what should I get? only admin token? or still both with no consideration to the UAC status?

    Read the article

  • Problem whit usb wireless mouse

    - by aiacet
    Recently i have thi problem whit my wireless mouse (Trust model on: www.trust.com/15313). Sometimes when i start the Pc or during a game the pointer/arrow stop to move it. In the Pc start the pointer is blocked on the center of the screen. If I'm lucky i have to chance the USB wirless adapter from port 1 to port 2 but sometimes this trick doesn't work i to use the mouse i have to restart. Like you can see in the productor webpage this mouse don't have the direver but only a tool to solve some problem. Thank you in advance to all the "super-users" that reading this question would be help me Ajax

    Read the article

  • Object or primitive type

    - by John
    Hi, Can someone explain to me the usage of Integer, Boolean etc in place of their primitive types in JAVA? I can't seem to grasp the advantages their are providing. They seem to create unnecessary problems of handling null values. Thanks!

    Read the article

  • Need to call COM component using reflection in .NET

    - by Usman
    I need to determine the COM component(unmanaged code) type and invoke the exposed interface's methods using reflection in C# at runtime. First What member of "Type" tells that type is COM component and we can take CLSID at runtime? Is Type.COMObject? I need to call methods of exposed interfaces as they called in unmanaged code using CoCreateInstance by passing CLSID and REFID ... I am using InvokeMember but it returns null or 0 as out parameter. How to pass out parameter in this case.? Is there any need to pass out parameter? As all my COM unmanaged code suppose to take last parameter as an OUT parameter and after executing it puts the result into that out param. But I've converted all my unmanaged COM code to .NET managed assemblies using tlbimp.exe.

    Read the article

  • OpenGL - lighting of vertices outside clip range

    - by hmp
    I have a problem with lighting in my OpenGL application. When one of the vertices of a drawn polygon goes outside the front clip plane (or has z<0, I'm not sure which), the polygon stops being lighted properly. This however happens on only one machine I tested, with Intel GMA950 card. On nVidia and ATI cards everything looks fine. I guess I am breaking some OpenGL rule here? How should I deal with it? I'd try dividing the scene into smaller polygons, but I'm not sure if it guarantees the case is eliminated (all polygons stepping outside the clipping range are offscreen).

    Read the article

  • Java Client interoperating with WSE 3.0 Web Service

    - by Dee
    I have a Interoperable Security Token Service (STS) that authenticates the User and then issues a SAML token. I also have transaction services that expects the SAML token in the incoming SOAP request header. For a client to make a call to transaction service, it first needs to authenticate with the STS, get the SAML token and then make a call to the transaction services. The STS is an interoperable service and can be invoked from a Java client. The Transaction services are build using WSE 3.0 framework, but the WSDL that it generates is not good enough for a Java client to understand it. I want my Java client to explicitly call the STS and then using the received SAML token make a call to Transaction Services. I tried with Netbeans and Metro WSIT toolkit. I was able to call the Transaction Services if it were implemented using WCF. With WCF Transaction Service the WSDL generated has complete information using which the Java client can figure out how to call to STS and then call the WCF Transaction service. How can my Java client explicitly call the STS and then in turn call the WSE 3.0 transaction services?

    Read the article

  • Command button requires two clicks (sometimes)

    - by Shelly
    i am using icefaces 1.8.2. For some command buttons, sometimes i need to click the button twice. previously whole applivcation was working fine with single click. after upgrade to 1.8.2,i am facing this problem......Any suggestion,what could be the reason??? Thanks

    Read the article

  • Properly releasing UITableViewController and UITableView directly added to a UIViewController

    - by JK
    I have a UIViewController (parentVC) to which I add a UITableViewController as follows (it is not pushed since the tableview only occupies about half the screen): tableVC = [[SmallTableVC alloc] initWithStyle:UITableViewStylePlain]; [self.view addSubview:tableVC.tableView]; In dealloc, I add [tableVC release]; Using instruments, I can see that the tableVC is indeed fully released when parentVC released, which is good, but I am not sure why as I thought that the UITableView of tableVC would have a retain count of 2 (1 for retention by tableVC and 1 for retention by parentVC). My intuition was that an additional [tableVC.tableView release] would be required, but adding it crashes the app. Why is tableVC released properly by the current code (if indeed it actually is)? Does a UITableViewController not retain its tableView? Thanks.

    Read the article

  • DataSet XML export is empty

    - by Shaine
    I've got in-memory dataset with couple of tables that is populated in code. Data-bound grids on the gui show table contents without a problem. Then I try to export the dataset into XML: ds.WriteXml(fdSave.FileName, XmlWriteMode.WriteSchema); and get empty XML (with couple of lines regarding dataset names but without any tables) If I export table directly I've got all the data but dataset name is obviously wrong: ds.Fields.WriteXml(fdSave.FileName, XmlWriteMode.WriteSchema); What am I missing? Is there any reasonable way to write the whole dataset into file?

    Read the article

  • Discovering the default gateway without DHCP

    - by JavaRocky
    A crazy question, but is there anyway to discover the default gateway without DHCP? This would be for a device on a network which does not use DHCP which does not have an IP address as yet. I was thinking if I could discover the default gateway, then i could try to guess an unused ip address then broadcast on the network to see if it's being used. I may be asking for trouble i understand. E.g. if there is already a computer which has a static IP and is shutdown.

    Read the article

  • How to force main Acivity to wait for subactivity in Android?

    - by rmaster
    hi, I am calling a subactivity from main activity. This subactivity should take few numbers from user (i'm using Edit text control to achieve this), save them to static variable in another class and terminate. I want main activity to wait for subactivity but both are just running simultaneously. Even doing sth like that doesn't help: Thread t = new Thread(new Runnable(){ public void run(){ Log.v("==================", "run "+new Date()); startActivityForResult(new Intent(ctx,myCustomSubactivity.class),1); } }); Log.v("==================", "calling run "+new Date()); t.start(); try { t.join(); } catch (InterruptedException e) {Log.v("==================", "can't join");} Log.v("==================", "back from activity "+new Date()); do you know how to force main activity to wait? Thread.wait() method is not supported in Android(program throws error).

    Read the article

  • Stop scrolling to top in UIWebView - iPhone

    - by sagar
    I have placed following javascript in my html file. <script TYPE="text/javascript"> function srk(){ document.ontouchmove = function(e){ e.preventDefault(); } } </script> I am scrolling my webview by following code with some animation. [myWebView stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat: @"window.scrollTo(0,%i);",414*self.initialScrollPosition]]; Everything going right, but on problem that I am facing is as follows. Whenever User/I tap on the status bar of iPhone, WebView Bydefault scrolls to top. This should not be done. Is it possible to prevent inbuilt functionality ? I know one of the option is as follows. ((UIScrollView *)[[myWebView valueForKey:@"_internal"] valueForKey:@"scroller"]).scrollsToTop = NO; But is it valid to do ?

    Read the article

  • View Images and Videos in 3D in Firefox

    - by Asian Angel
    Different websites have their own format for viewing images and videos, but may not be a lot of fun to use. The Cooliris extension for Firefox lets you view those same images and videos in a dynamic 3D format. Before For our example we conducted a search for nature photos at Flickr. You could view them in a static format or even as a slideshow but what about something more dynamic looking? After As soon as the extension has finished installing, you will notice a new toolbar button used for launching the Cooliris tab. When you launch the Cooliris tab you will have an expandable menu system in the upper left corner. A speed dial setup in the center. And a small toolbar in the lower right corner Before going further you should check and make any desired adjustments in the preferences to enhance your viewing experience. In the upper right corner you can start your search by selecting from the available sources. The same search for nature images is more focused and clean looking this time. Clicking on an image will bring it forward and enlarge it. You can use the slider tool at the bottom of the tab to browser left or right through the images and videos. And when you find one that interests you, click on the popout button to open it in a new tab. Conclusion The Cooliris extension makes viewing images and videos fun and interactive with its’ 3D style format. Links Download the Cooliris extension (Mozilla Add-ons) Download Cooliris for Firefox, Internet Explorer, Safari (Mac Only), & Chrome Similar Articles Productive Geek Tips Make Firefox Display Large Images Full SizeInstalling Windows Media Player Plugin for FirefoxStop YouTube Videos from Automatically Playing in FirefoxShare Text & Images the Easy Way with JustPaste.itEasily View Source of Included Files in Firefox TouchFreeze Alternative in AutoHotkey The Icy Undertow Desktop Windows Home Server – Backup to LAN The Clear & Clean Desktop Use This Bookmarklet to Easily Get Albums Use AutoHotkey to Assign a Hotkey to a Specific Window Latest Software Reviews Tinyhacker Random Tips VMware Workstation 7 Acronis Online Backup DVDFab 6 Revo Uninstaller Pro FetchMp3 Can Download Videos & Convert Them to Mp3 Use Flixtime To Create Video Slideshows Creating a Password Reset Disk in Windows Bypass Waiting Time On Customer Service Calls With Lucyphone MELTUP – "The Beginning Of US Currency Crisis And Hyperinflation" Enable or Disable the Task Manager Using TaskMgrED

    Read the article

< Previous Page | 20 21 22 23 24 25 26 27 28 29 30 31  | Next Page >