Welcome Guest, Not a member yet? Register   Sign In
  Session Lost after Payment gateway redirection to Merhcant site
Posted by: Austin638 - Today, 03:09 AM - Replies (2)

  I m using codeingniter4, and php 7.3, Integrated a Payment Gateway . From the response url i m getting values into my controller function.

  Issue is Session is unsetting after receving the response from payment gateway.


  redirecting from another method
Posted by: vgrigorov - Today, 01:57 AM - Replies (2)

butHello, all,
I have the following question. In my controller (Service) I easily redirect with:

PHP Code:
return redirect()->to('http://' $_SERVER['HTTP_HOST'] . $this->data['router']['edit'] . $Id '?add=1'); 


But when I call some method from my controller and this method is defined in the BaseController for example, the redirection does not work.
Here is a fragment from my code, In my controller:
PHP Code:
class Service extends BaseController
{
    public function edit()
    {
        $this->editData();
    }


And here is the editData() method in the BaseController

PHP Code:
protected function editData($Id)
    {

        if ($this->request->getMethod() === 'post') {
            if ($Id) {
                $res $this->saveData($Id);
                $this->data['res'] = ['type' => 1'mess' => ($res) ? lang($this->data['lang'] . '.mess.ok.edit') : lang($this->data['lang'] . '.mess.err.edit')];
            } else {
                $Id $this->saveData();
                if ($Id) {
                    return redirect()->to('http://' $_SERVER['HTTP_HOST'] . $this->data['router']['edit'] . $Id '?add=1');
                } else {
                    $this->data['res'] = ['type' => 0'mess' => lang($this->data['lang'] . '.mess.err.add')];
                }
            }
        }
    

If I change it to "return editData()" in my edit() method it works, but this does not works for me. So is there a way to redirect directly from the editData method?


  How to set dynamic base_url in codeigniter 4.2.2
Posted by: startup - Yesterday, 11:49 PM - Replies (2)

i have one url below in app.php

PHP Code:
public $baseURL 'http://localhost:8080/ciall/ci4/ci422/'

i want  base_url dynamic below

PHP Code:
public $baseURL '://'.SEVER['HTTP_HOST'].'/ciall/ci4/ci422/'


  Upgrading from 4.1.9 to 4.2.0 issues
Posted by: fre2mansur - Yesterday, 06:45 PM - Replies (1)

Hello Everyone, I would like to upgrade my CI from 4.1.9 to 4.2.4 as well as PHP if its required. 

I have installed the CI CMD tool

Code:
composer create-project codeigniter4/appstarter 
My CI Version is 
Code:
CodeIgniter v4.1.9 Command Line Tool - Server Time: 2022-08-15 20:12:37 UTC-05:00

My PHP Version is
Code:
PHP 7.3.5 (cli) (built: May  1 2019 13:17:17) ( ZTS MSVC15 (Visual C++ 2017) x64 )


I tried 
Code:
composer update
i get return as Nothing to install or update

Mandatory File Changes
I have upgraded the thease files from 
public/index.php  // https://github.com/codeigniter4/CodeIgniter4/blob/v4.2.0/public/index.php
spark //https://github.com/codeigniter4/CodeIgniter4/blob/v4.2.0/spark

I run again composer update same response as Nothing to install or update and when i run the app php spark serve
I got this error

Call to undefined method CodeIgniter\CodeIgniter::setContext()

at ROOTPATH\spark:72


  trouble starting
Posted by: dum1 - Yesterday, 01:05 PM - No Replies

I downloaded CI4, extracted it and renamed the folder to ci4.
สมัครเอเย่นต์สล็อตเว็บufabet
Then I added the virtual host:


  Title Suggestions
Posted by: Ramipa Pimma - Yesterday, 11:29 AM - No Replies

Hai All,

I'm a Computer Science student and have to complete my final year project. I am looking for title suggestions as this actually seems to be the most complicated aspect of the whole project.
 
Im going to develop with CodeIgniter . I hope someone can help me  !


  set up
Posted by: dum1 - Yesterday, 11:17 AM - No Replies

When validation fails for one of the textarea inputs The field will not be re-populated. (I don't see how it will continue to work.)
สมัครเอเย่นต์สล็อตufabetเว็บตรง
It works great when names are not arrays and I use address1, address2 and address3 instead.


  extention of autorouter in ci4.2
Posted by: dokitura - Yesterday, 09:34 AM - Replies (1)

Hi.

I'm working on a CI4.1.9 application, which extends the default-handling of auto-routing (existing since CI3) more deeply.

Yesterday i've read about the problem, which comes with that handling concerning creating vulnerable apps where controller filters or CSRF protection are bypassed . On shorthand i decided to upgrade to CI4.2.3, but stumbled over these problems:

  • both new classes for auto-routing (AutoRouter and AutoRouterImproved) can't be extended, since they are both finalized
  • and they also seem to be instantiated directly via new keyword (e.g. https://github.com/codeigniter4/CodeIgni...r.php#L136) instead by some Service-method or equal
So my questions would be:
  • is there any way, to extend new auto-routing handling (except writing a complete own handler for this)?
  • if not, is it maybe planned for a future ci-version, to establish the instantiation more dynamically like via service-method, etc.?
Thanks in advance.

(I'm willing to share more info, if you need anything ;-))

Greetings,
doki


  CI 4 & VUEJS
Posted by: devo - Yesterday, 06:16 AM - Replies (3)

hii are someone know how to add vuejs to CI4


  FrameworkException Missing Extension
Posted by: ramonhenry - Yesterday, 05:47 AM - Replies (2)

I have just installed codeigniter 4 and I'm receiving the following error

PHP Code:
foreach ($requiredExtensions as $extension) {
            if (! extension_loaded($extension)) {
                $missingExtensions[] = $extension;
            }
        }
 
        if ($missingExtensions !== []) {
            throw FrameworkException::forMissingExtension(implode(', '$missingExtensions));
        }
    }
 
    /**
      * Initializes Kint
      */
    protected function initializeKint()

I have already enabled intl extension but it's still saying that it cannot find it. I have even restarted and done a full clean and install but till receiving this error 


Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Latest Threads
Suggestion: Order by is n...
by iRedds
1 hour ago
Session Lost after Paymen...
by kenjis
1 hour ago
FrameworkException Missin...
by kenjis
1 hour ago
redirecting from another ...
by kenjis
1 hour ago
Upgrading from 4.1.9 to 4...
by captain-sensible
8 hours ago
extention of autorouter i...
by kenjis
Today, 01:59 AM
Shield validation questio...
by chronic
Today, 12:48 AM
How to set dynamic base_u...
by kenjis
Today, 12:10 AM
trouble starting
by dum1
Yesterday, 01:05 PM
add CI4 view features lik...
by kilishan
Yesterday, 12:25 PM

Forum Statistics
» Members: 40,606
» Latest member: netpozyczka24
» Forum threads: 75,307
» Forum posts: 367,079

Full Statistics

Search Forums

(Advanced Search)


Theme © iAndrew 2016 - Forum software by © MyBB