Jump to content

trq

Staff Alumni
  • Posts

    30,999
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by trq

  1. Not without a description of your problem. My guess? Strings need quotes within SQL. $tsql = "EXEC CPS_ADD_NEW_USER @agentF = 'php',@agentS='test'";
  2. You will need to schedule a job via your servers OS. Cron on Linux or Scheduler on Windows.
  3. Sorry? rand has min & max arguments.
  4. If you can access the file via the web, it is somewhere within the document root, sub directory or not. You need to place them above (outside of) the document root.
  5. Files that aren't designed to be accessed directly should be stored outside of your servers document root and there location should be added to your include path. failing the ability to do so (shity shared hosting) you can define a constant within the file calling the include, then check for the existence of that constant within the include itself. eg; <?php define('IS_WITHIN_APP', true); include 'foo.php'; // more code foo.php <?php if (!defined('IS_WITHIN_APP')) { die('Bugger Off!'); }
  6. It refers to the html tags which will have the session id appended to them if (when) cookies are disabled. Session should only use cookies for securities sake and the option to use cookies only (see session.use_only_cookies) has been set to true since 4.3. This basically means that url_rewriter.tags is now redundant by default.
  7. It does sound to me like you might be heading slightly down the wrong path. I myself have an application shared by many users. However, each user has there own apache vhost configured, they have there own document root, apache logs, mysql database and application configurations. It works something like so.... The framework (in your case Zend though we found it much too slow and developed our own) lives in.... /usr/share/php/Zend The application libraries (models, controllers) live in /usr/share/php/AppName And the client specific code lives within..... /var/www/site/<domainname> Each client may have code specific to them, and the include path should be set accordingly. eg; include /var/www/site/<domainname>/libs before /usr/share/php/AppName before /usr/share/php/Zend This setup would allow for finer grained control over the application configurations and can also allow for more prominent clients to be moved to other servers (for example) without too much trouble. Currently I (we) run a CMS application with almost 900 clients using this same method and are working on another (similar) application at present.
  8. No idea why your getting that error, but considering your function has no error checking of any kind anyway it could be made allot simpler. function __autoload($class_name) { include strtolower($class_name) . '.php'; }
  9. 'no access to db' is not a mysql error. What exactly is the proper error you are receiving?
  10. Ive given you the answer. Eval is almost always a poor design choice, what else do you want me to say? I would never recommend the path your trying to go down.
  11. Instead of your users needing to remember to type <?php echo $page->id('mines_DwarvenMines') ?> to have a simple id displayed within there link, your editor should have a mechanism for supplying these id's from a drop down or some such other UI element.
  12. This topic has been moved to Application Design. http://www.phpfreaks.com/forums/index.php?topic=314887.0
  13. a) No b) Not presently, flash is still the most viable option. c) ?
  14. This topic has been moved to Miscellaneous. http://www.phpfreaks.com/forums/index.php?topic=314885.0
  15. PHP is not meant to be stored within a database, and while it is possible, I would suggest it is a poor design choice.
  16. This topic has been moved to mod_rewrite. http://www.phpfreaks.com/forums/index.php?topic=314893.0
  17. This forum has tags for a reason, please use them. ps: you might want to describe your actual problem as well.
  18. The closest you'll get with php is to have a look within the $_SERVER array and see if anything is in there anywhere. otherwise, your going to need to prod around client side, PHP can't really help you.
  19. trq

    Popup window

    You need to get yourself a decent editor at minimum. Nobody should need help with these types of errors. echo ' <a onClick="window.open(\'annexplayerpop.shtm\',\'popup\',\'height=275,width=425,top=130,left=280,scrollbars=no\')" target="popup"><img src="popupbutton-blue-bg.png" title="Popup MP3 Player" border="0" height="45" width="58"></a> ';
  20. http://framework.zend.com/manual/en/learning.quickstart.intro.html
  21. trq

    Popup window

    You need to escape single quotes within a single quoted string.
  22. Yes. You can find the user & group Apache runs under within Apache's main configuration file httpd.conf.
  23. You might also want to checkout http://jquerymobile.com if your writing mobile apps for smartphones. It makes things so much simpler.
×
×
  • 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.