Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

some code works in admin but not front end 06 Nov 2012 18:57 #5021

UPDATE: Solved myself after I realized I'm a moron.

Hello,

I have a line of code running a shell_exec() command in admin/tables/filename.php that does work perfectly on the admin side, but that line fails when the user executes the same item.

Ideas? Might be related to my other post regarding the error in jmodel.tem.php

www.j-cook.pro/forum/7-design-your-appli...itemphp-upload-class
--
Jerry Benton

Please Log in or Create an account to join the conversation.

Last edit: by jcbenton.

Re: shell_exec work in admin but not front end 06 Nov 2012 19:06 #5023

Nevermind. This was an error on my part. The backend passes some information that the front end does not have. Thinking up a work around :p
--
Jerry Benton

Please Log in or Create an account to join the conversation.

Re: shell_exec work in admin but not front end 06 Nov 2012 19:19 #5024

Yay!
if(!isset($this->encoder)){
	// Get the default encoder
	$dbm = JFactory::getDBO();
        $querym = $dbm->getQuery(true);
        $querym->select('id');
        $querym->from('#__skm_encoders');
        $querym->where("default_encoder = '1' LIMIT 1");
    	$dbm->setQuery($querym);
	$encoder = $dbm->loadRow();
	$this->encoder = $encoder[0];
}
--
Jerry Benton

Please Log in or Create an account to join the conversation.

Last edit: by jcbenton.
  • Page:
  • 1
Time to create page: 0.054 seconds
  let me say what a brilliant app! Thank you very very much for all the hard work to build Cook!
Tocpe (Forum)

Get Started