I have a function that redirect to an external URL with parametre, but I want to redirect it to a new tab , This my code
public function urlAction(){
$directory= $user->getDirectory();
return $this->redirect('http://localhost/sound/index.html?directory='.$directory );
}
I want to open the link in new tab. any suggestion please?
The only answer possible here is that you can't redirect in a new tab .
You can provide links that open in a new tab or window using the target in html or a function in php, but you can't have a redirect.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.