Jump to content

 

nil2567

Member Since 24 Dec 2014
Offline Last Active Apr 04 2016 04:42 PM
-----

Topics I've Started

Link To Go To Controller

24 December 2015 - 03:29 PM

hello,

 

Im trying to create a link to go to controller end get information to display in a html block.

 

when I click the link I got a 200 ok and it will go to controller and get the info but the html wont update.

 

here is the code:

 

    <div id="content_xxx">
            <a class="cm-ajax" id="xxx" data-ca-target-id="content_xxx" href="{"orders.manage&test=1"|fn_url}">xxxxxxxxxxxxxxxxxxx</a>
 
        <ul>
            <li>{$li}</li>
            <li>22222222222</li>
            <li>33333333333</li>
        </ul>
    </div><!-- content_xxx -->
 
and controller:
 
        $a = 1111;
    if($_REQUEST['test'] == 1){
        $a = 'aaaaaaaaaaaa';
        Registry::get('view')->assign('li', $a);
        Registry::get('ajax')->assign('li', $a);
 
 
    }
 
what is missing here ?

 


Link To Go To Controller

24 December 2015 - 03:25 PM

hello,

 

Im trying to create a link to go to controller end get information to display in a html block.

 

when I click the link I got a 200 ok and it will go to controller and get the info but the html wont update.

 

here is the code:

 

    <div id="div_id_to_be_updated">
            <a class="cm-ajax" id="xxx" data-ca-target-id="content_xxx" href="{"orders.manage&test=1"|fn_url}">xxxxxxxxxxxxxxxxxxx</a>
 
        <ul>
            <li>{$li}</li>
            <li>22222222222</li>
            <li>33333333333</li>
        </ul>
    </div><!-- content_xxx -->
 
and controller:
 
        $a = 1111;
    if($_REQUEST['test'] == 1){
        $a = 'aaaaaaaaaaaa';
        Registry::get('view')->assign('li', $a);
        Registry::get('ajax')->assign('li', $a);
 
 
    }
 
what is missing here ?

 


Redirect From Controller With Error

09 March 2015 - 02:21 PM

Hello People,

do you know if there is a way to redirect from controller with an error message?

I can use:

return array(CONTROLLER_STATUS_REDIRECT, 'Message Here');

but that message will return a green box and I need a red box telling there was an error.

Thanks

Create Table From Controller

05 March 2015 - 11:52 AM

Hello,

I'm getting values from a form in my controller after click submit.

Untill here everything ok.

What I need now is to save these values in the DB and I don't know if:

* I have to create a new table in the DB

Ex: db_query("CREATE TABLE IF NOT EXESTS bla bla bla bla]);


* or if I cscart has a method to do that automaticly.

......

New Field To Export Products

16 February 2015 - 06:54 PM

hello forum,

I need to add 1 new field to export products.

any idea on how m I going to get the payment method field and display on the options of "Available Fields" ?

thanks