Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
set-time-limit
- Page 1
set_time_limit() [function.set-time-limit]
Programming
Web Development
11 Years Ago
by johnny.lhc.9
… files,how to solve this problem? Warning: set_time_limit() [function.
set
-
time
-
limit
]: Cannot
set
time
limit
in safe mode in /home/indomari/public_html/administrator/includes/connect…
PHP set time limit
Programming
Web Development
14 Years Ago
by lyrico
… save record. But I want to have
time
limit
in saving the record. When the local
time
is 4:00 PM, the user… { $name = $_POST['name']; $age = $_POST['age']; $addr = $_POST['addr']; //if
time
is beyond 4:00 PM this code is enable ------ this…disable the saving codes echo "Can not save record.
Time
limit
has expire" }
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by pritaeas
[code] $hour = strftime('%H'); // 00-23 if ($hour >= 16) { echo "Can not save record.
Time
limit
has expire"; } else { mysql_query("insert into file(name,age,address) values ('$name','$age','$addr')"); echo "Record Save"; } [/code]
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by pritaeas
You can use [ code ] tags. [code] $
time
= strftime('%H%M%S'); if ($
time
> 160000) { echo "Can not save record.
Time
limit
has expired"; } else { mysql_query("insert into file (name, age, address) values ('$name', '$age', '$addr')"); echo "Record Saved"; } [/code]
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by karteek.vemula
… echo "Error in Insert query"; } }else{ echo "
Time
exceeded, You cannot insert into database. Try, again."; }
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by lyrico
[QUOTE=;][/QUOTE] how about the system accept is exactly until 4:00 PM only. but if the
time
is 4:01 PM, the system doest save the record? and another one, how can i write the code that appear as same as pritaeas code? thanks a lot guys.
[HELP] Time Limit
Programming
Web Development
15 Years Ago
by Mujahid158
How can I
set
a
time
limit
for a user to stay on a web page. Let …
Re: [HELP] Time Limit
Programming
Web Development
15 Years Ago
by diafol
… $delay = '30'; //countdown
time
in seconds for first
time
page entry $error_msg = ""; $_SESSION['allowed_view'] =
time
() + $delay; //
set
time
at which page can…[B]second page[/B] [CODE=php]<?php session_start(); $current =
time
(); if(!isset($_SESSION['allowed_view']) || $current < $_SESSION['allowed_view']){ …
Re: set_time_limit() [function.set-time-limit]
Programming
Web Development
11 Years Ago
by pritaeas
Apparently your server has safe_mode enabled, thus disabling the use of that particular function. If this is on a shared host, I doubt there's a way to enable it. Contact your host.
Re: set_time_limit() [function.set-time-limit]
Programming
Web Development
11 Years Ago
by phorce
Hey, Try the following: `ini_get('safe_mode')` Before the function declation, if you've compiled PHP with `--enable-safe-mode then defaults to On, otherwise Off.` then this error would happen. For more information, check the following: [Here](http://php.net/manual/en/ini.sect.safe-mode.php#ini.safe-mode) Hope this helps you.
Re: set_time_limit() [function.set-time-limit]
Programming
Web Development
11 Years Ago
by johnny.lhc.9
owh, that while it shows an error. i think that script not work. thank you sir
Re: set_time_limit() [function.set-time-limit]
Programming
Web Development
11 Years Ago
by johnny.lhc.9
i have put this code in php.ini at my script locate safe_mode = OFF disable_functions = NONE it work nice :)
Script ignoring time limit?
Programming
Web Development
14 Years Ago
by mikeflash
… site's database. My hosting provider has a 120 second
time
limit
for PHP scripts, which is too low for my script… the cron tasks run for their full duration ignoring the
time
limit
, and I haven't used [ICODE]set_time_limit(0);[/ICODE] in… re-checked my host's php.ini and yes, the
time
limit
is
set
to 120. Any ideas why this is happening? I…
Re: Script ignoring time limit?
Programming
Web Development
14 Years Ago
by mikeflash
Well, that could work, since there's indeed a loop involved. Thanks. But, any ideas why would the script ignore the
time
limit
set
in php.ini? It doesn't make sense.
Re: Script ignoring time limit?
Programming
Web Development
14 Years Ago
by maba001
… that long. Actually I don't know how reliable the
time
limit
really is. I have seen similar behavior but only in…
Re: Java time limit / Timer
Programming
Software Development
14 Years Ago
by JamesCherrill
Set
the timer to fire (eg) once a second. In the … count of the total seconds. When the total reaches your
time
limit
, stop the timer and do whatever else is needed. The…
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by lyrico
[QUOTE=;][/QUOTE] Thanks for the reply guys. I really appreciated that.
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by lyrico
thanks again pritaeas
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by pritaeas
Forgot... you need to close the tag with [ /code ] too.
Re: PHP set time limit
Programming
Web Development
14 Years Ago
by lyrico
[QUOTE=;][/QUOTE] just want to make a sample ^^, [code] <?php echo "sample"; ?> [/code]
Re: [HELP] Time Limit
Programming
Web Development
15 Years Ago
by Mujahid158
… as I want the user to wait for the specific
time
before going to page b. If the user visits page… ad, the error is shown to you with the remaining
time
you've to wait...
Re: [HELP] Time Limit
Programming
Web Development
15 Years Ago
by Manuz
With the help of Ajax you can achieve this. Call a timer function onload inside body tag.After its execution do your task.May be you can show the link to pageB only at that
time
.
Re: [HELP] Time Limit
Programming
Web Development
15 Years Ago
by diafol
… it via header refresh. The plain js window.location using
time
intervals is the usual method, but if js is not…
Re: Time limit on data inserted
Programming
Web Development
15 Years Ago
by network18
… page. Almost like Ebay displays users data for a limited
time
(say 3 days) but the user can relist the item… and has been passed three days. So you will just
set
the flag or status as "inactive" or "…
Re: Time limit on data inserted
Programming
Web Development
15 Years Ago
by phpDave
[QUOTE=network18;1094440]you will need to execute the cron scheduled to execute daily, which will check if there is any data whose creator user has not paid and has been passed three days. So you will just
set
the flag or status as "inactive" or "unpublish" against that data.[/QUOTE] Thanks.
Re: Script ignoring time limit?
Programming
Web Development
14 Years Ago
by maba001
In case you are looping, you could just do the following: [CODE] $starttime =
time
(); ... foreach (....) { // your loop // your active code here .... if (
time
() - $starttime) > 120) break; } [/CODE] Would be the simplistic approach.
Re: Get rid of the editing time limit!!!!!
Community Center
Meta DaniWeb
17 Years Ago
by Ancient Dragon
… mix tabs and spaces like that, its not just DaniWeb.
Set
your original code editor to use only spaces and not…
Re: Get rid of the editing time limit!!!!!
Community Center
Meta DaniWeb
17 Years Ago
by iamthwee
If you really are using notepad as your editor with spaces instead of tabs, with the daniweb editor
set
to standard mode instead of wysiwyg mode (although using notepad wouldn't affect this), I can't see what the problem is? Prove me wrong.
Re: Help with time limit please
Programming
Web Development
14 Years Ago
by chrishea
… as long as 20 minutes, you will need to
set
the maximum
time
that your program is allowed to run as you… will exceed the normal system default for the system to
time
…
Re: Help with time limit please
Programming
Web Development
14 Years Ago
by vibhaJ
… have posted code which will work for 5second, you can
set
urs. [CODE] <html> <head> <script…
1
2
3
17
Next
Last
Search
Search
Forums
Forum Index
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2025 DaniWeb® LLC