Umm like yeah...
In so many ways I have loved CMS Made Simple because, well, it helps create websites for clients.
However, EVERY time there is a version change.
JESUS TAP DANCING CHRIST do you have to change the fundamental underlying code?
As I go from 1.4 to 1.5
EVERY WHERE I have some sort $this->CreateLink(
I get screwed!!!
Here is how an old link looks and AMAZINGLY the new module API STILL works!!!! Fix IT!
moduleinterface.php?mact=modulecreator,m1_,reset,0&_s_=82833b88
here is the code that used work very well:
header( "Location: ".$this->CreateLink( $id , 'defaultadmin' , $returnid , '' , '' , '' , true ) );
or
What is _s_?
Apparently now instead of mact= its module=....
Great, good, you finally named a GET var nicely.... But then update the CreateLink func to handle it. As it stands the users gets booted out to the login screen. NOT GOOD!
I and I am sure many others are royally f'd because none of the websites that we have with 1.4 that use modules are able to be upgraded.
At the very least you could have on your home page a HUGE tag, blinking, saying:
ATTENTION UPGRADING WILL BONE YOU!
I'm sorry to be upset but I really thought that I was going to be able to enjoy my weekend.
[SOLVED] $this->CreateLink in new version
[SOLVED] $this->CreateLink in new version
Last edited by brownrl on Fri Dec 05, 2008 2:06 pm, edited 1 time in total.
Re: $this->CreateLink in new version
I think _s_ is the new session key which is appended to each and every URL in the admin console.
If you're using the module API's CreateLink method to create your links the URL may change, but things should work without any problems. Normally you don't use the URL itself, but pass parameters which will be available in the called module action.
Regards,
D
If you're using the module API's CreateLink method to create your links the URL may change, but things should work without any problems. Normally you don't use the URL itself, but pass parameters which will be available in the called module action.
Regards,
D
FOUND: Re: $this->CreateLink in new version
One piece of the puzzel
foreach() in /home/garage/public_html/internal/eurowebsite/lib/classes/module_support/modform.inc.php on line 438
There isn't a check there to make sure that the params maybe empty....
so a warning gets thrown up
changed:
added
if( is_array( $params ) && count( $params ) )
to on 441
modform.inc.php
foreach() in /home/garage/public_html/internal/eurowebsite/lib/classes/module_support/modform.inc.php on line 438
There isn't a check there to make sure that the params maybe empty....
so a warning gets thrown up
changed:
added
if( is_array( $params ) && count( $params ) )
to on 441
modform.inc.php
UNSOLVED: $this->CreateLink in new version
Ok,
going further it appears that in the newer version you can't have a redirect in admin modules.
any kind of call to:
header( "Location: ....
-- tried many ways --
Breaks something and it goes to the login screen. So lets say you have a module called "cars".
And you have an action called "create_car".
Lets say after "creating your car" you want to go back to the default admin action...
well.... not possible it appears now...
Look I am all for safe software....
BUT carrying some unique session_id arround on the get url string is a little bit well... amateur hour?
going further it appears that in the newer version you can't have a redirect in admin modules.
any kind of call to:
header( "Location: ....
-- tried many ways --
Breaks something and it goes to the login screen. So lets say you have a module called "cars".
And you have an action called "create_car".
Lets say after "creating your car" you want to go back to the default admin action...
well.... not possible it appears now...
Look I am all for safe software....
BUT carrying some unique session_id arround on the get url string is a little bit well... amateur hour?
Re: $this->CreateLink in new version
If you pass the "params" parameter to the CreateLink method it should be an (empty) array, not a text string.
The API docs say 'string', but this is incorrect.
Regards,
D
The API docs say 'string', but this is incorrect.
Code: Select all
$this->CreateLink( $id , 'defaultadmin' , $returnid , '' , array() , '' , true )
D
Re: UNSOLVED: $this->CreateLink in new version
Use either the Redirect or DoAction method.brownrl wrote: any kind of call to:
header( "Location: ....
-- tried many ways --
Breaks something and it goes to the login screen. So lets say you have a module called "cars".
And you have an action called "create_car".
Lets say after "creating your car" you want to go back to the default admin action...
well.... not possible it appears now...
The reasons for this ID in the URL are explained here.brownrl wrote: Look I am all for safe software....
BUT carrying some unique session_id arround on the get url string is a little bit well... amateur hour?
Regards,
D
Re: $this->CreateLink in new version
ok
redirect seems to be new?
but works for the time being....
thanks a ton I was pooping my pants on this... 1000 apologies!
redirect seems to be new?
but works for the time being....
thanks a ton I was pooping my pants on this... 1000 apologies!
Re: $this->CreateLink in new version
Redirect and RedirectForFrontEnd have been around since at least version 0.13brownrl wrote: redirect seems to be new?
but works for the time being....
Not a problem, you can put on some clean ones nowbrownrl wrote: thanks a ton I was pooping my pants on this... 1000 apologies!

Regards,
D