Jump to content

[SOLVED] Stop included script


Stooney

Recommended Posts

Is it possible to stop execution of an included script without stopping execution of everything else?

 

In this example, the exit() in file1.php would stop everything and stuff2() won't happen.  Is there a way to just stop file1.php and continue what was going on outside of the include?

<?php
stuff();
include('file1.php');
stuff2();
?>

 

file1.php

<?php
exit();
dont_do_this();
?>

Link to comment
https://forums.phpfreaks.com/topic/124716-solved-stop-included-script/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.