Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. pr0fess0r

    Using // in a RewriteRule

    Hi all I followed the tutorial here: http://www.shadow-fox.net/site/tutorial/45-Create-Dynamic-URLs-With-Mod-Rewrite-and-PHP-Functions to create a rewrite rule so that http://blah/index.php?id=7&page=4 could be written http://blah/index//id/7/page/4/ for search engine friendliness, but it's not...
  2. pr0fess0r

    Saving an XML file modified by XPath

    Sorry if I wasnt clear The code above successfully appears to add a unique integer to any blank id attributes it finds, what I need to be able to do is update $file with the change. From what I read of XPath, there is a way to dump all of the nodes out as one string and write them to a file, but...
  3. pr0fess0r

    Saving an XML file modified by XPath

    Hi Is it possible to save a modifed XML file in Perl's XPath? I have a script that looks for blank id attributes in an xml file and populates them with a unique ID... my $updated=0; my $xp = XML::XPath->new(filename => $file); my $nodeset = $xp->find('//@id'); # find all ids foreach my...
  4. pr0fess0r

    Including external SSL content

    So I could use <!--#include file=&quot;https://www.blah.com&quot;--> ?
  5. pr0fess0r

    Including external SSL content

    Hi I come from a PHP background and would like to know the code to include content from an external URL. In PHP, it's <? include(&quot;http://www.blah.com&quot;); ?> and to include content from a secure URL, it's <? $ch = curl_init(); curl_setopt ($ch, CURLOPT_URL...
  6. pr0fess0r

    Copying a symbol

    Hmm, that doesnt seem to work. 1. I opened the Library and duplicated the symbol by right-clicking and choosing Duplicate 2. Renamed it when prompted 3. Left dragged it onto the Stage 4. If I edit the text in this new instance of the duplicate symbol, the text also changes in the instance of the...
  7. pr0fess0r

    Copying a symbol

    Thanks guys
  8. pr0fess0r

    Copying a symbol

    Hi, this is a newbie question, but how do I copy and paste a symbol in such a way that it is no longer linked to the original, ie so the copy does not become an instance? I have a symbol I want to use innumerous places but with different text and despite using the techniques in the help, I cant...
  9. pr0fess0r

    deleting file from ftp site

    Hi Whats the best approach to overwriting a file from an ftp site with PHP? I know you cant overwrite a file with fopen, but I dont want to use ftp functions to log in and delete the file because I am using fopen to stream data from a variable into a file, i.e. I'm opening the connection with...
  10. pr0fess0r

    popup when browser closes but NOT when browing to another page

    Hi How can I have an event fire off (i.e. a popup) when a user closes their browser or clicks an offsite link, but not when they submit a form or follow a link on the page. I have an &quot;edit article&quot; page where a user updates details in a form. During this time the article is locked. If...
  11. pr0fess0r

    client and server timezone woes

    although it does work on our local development environment...
  12. pr0fess0r

    client and server timezone woes

    Hmm that didnt work <SCRIPT LANGUAGE=&quot;JavaScript&quot;><!-- var today = new Date(); var difftime = (today.getTimezoneOffset()+420) *60000; today.setTime(today.getTime()+difftime); document.form.clienttime.value=(today.parse)/1000; //--></SCRIPT> Gives me NaN for the value of clienttime on...
  13. pr0fess0r

    client and server timezone woes

    Thanks Boss, I'll give that a try By the way, whats the +420 for?
  14. pr0fess0r

    client and server timezone woes

    OK, so this will return the difference between the client machine's time and UTC/GMT. So, in order to calculate the difference between the server's time and the client's time, I need to get the offset between the server's time and UTC as well and then take the difference, is that right?
  15. pr0fess0r

    client and server timezone woes

    OK thanks, how would I get UTC epoch seconds? or at least get the difference between my local time and the server time in hours?
  16. pr0fess0r

    client and server timezone woes

    Ah OK, then the answer is no, because when I convert the server time from a unix timestamp to human readable form (<?=date(&quot;F j Y, g:i a&quot;)?>) I get May 5 2003, 4:05 am and this javascript: <SCRIPT LANGUAGE=&quot;JavaScript&quot;><!-- var now = new Date(); var...
  17. pr0fess0r

    client and server timezone woes

    Yes but my question is, where is it getting the time from? The web server or the client's machine? The code I posted seems to return identical values for both time() (PHP) and epoch_seconds (Javascript) yet they should be different because Javascript is getting the time from my machine and php...
  18. pr0fess0r

    client and server timezone woes

    But doesnt Date.getTime() run on the client machine, and return the client's time? My machine is set to NZT i.e. New Zealand Time, and the server is in Florida...
  19. pr0fess0r

    client and server timezone woes

    Hi I am trying to bypass the whole issue with a server being in one timezone and clients in the other by being a bit clever. Having the user choose a tiemzone froma dropdown isnt working for me - daylight savings etc always seems to screw the time up, so what I am doing is passing a hidden...

Part and Inventory Search

Back
Top