The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Need some code to enable new tab

View previous topic View next topic Go down

Solved Need some code to enable new tab

Post by Bangernomics on January 31st 2013, 4:08 pm

I need this code so that when its clicked it opens in a new tab, can anyone help?

Code:
<a href="http://volkszone.com"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg"></a>



Last edited by Bangernomics on January 31st 2013, 11:57 pm; edited 1 time in total

Bangernomics
Forumember

Female Posts : 144
Reputation : 1
Language : English
Location : UK

Back to top Go down

Solved Re: Need some code to enable new tab

Post by runawayhorses on January 31st 2013, 4:11 pm

You add a target="_blank" like this below:

Code:
    <a href="http://volkszone.com"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg" target="_blank"></a>

runawayhorses
Hyperactive

Male Posts : 2537
Reputation : 162
Language : English
Location : United States

http://runawayhorses.alldiscussion.net/

Back to top Go down

Solved Re: Need some code to enable new tab

Post by Sir Chivas™ on January 31st 2013, 4:12 pm

Hi,

Code:
<script type="text/javascript">window.open('http://google.com');</script>
Either that, or add target="_blank" to the originating link/form which landed in this "Photo Gallery Redirect" page.

Code:
<a href="http://google.com" target="_blank">click here</a>
or

Code:
<form action="http://google.com" target="_blank">
    <input type="submit" />
</form>

or
Code:
<meta http-equiv="refresh" content="5; URL=javascript:window.open('http://google.com','_parent');">

Sir Chivas™
Support Moderator
Support Moderator

Male Posts : 6756
Reputation : 428
Language : English, Spanish, and French
Location : || CSS || HTML || Graphics Designs || Support ||

Back to top Go down

Solved Re: Need some code to enable new tab

Post by Bangernomics on January 31st 2013, 4:25 pm

@runawayhorses wrote:You add a target="_blank" like this below:

Code:
    <a href="http://volkszone.com"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg" target="_blank"></a>

Tried this but it doesn't open in a new tab

Code:
    <a href="http://volkszone.com"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg" target="_blank"></a>

Bangernomics
Forumember

Female Posts : 144
Reputation : 1
Language : English
Location : UK

Back to top Go down

Solved Re: Need some code to enable new tab

Post by Bangernomics on January 31st 2013, 4:57 pm

Can you tell me how I should add it to my code? sorry but its not clear to me and I know nothing about code


CJ11™ wrote:Hi,

Code:
<script type="text/javascript">window.open('http://google.com');</script>
Either that, or add target="_blank" to the originating link/form which landed in this "Photo Gallery Redirect" page.

Code:
<a href="http://google.com" target="_blank">click here</a>
or

Code:
<form action="http://google.com" target="_blank">
    <input type="submit" />
</form>

or
Code:
<meta http-equiv="refresh" content="5; URL=javascript:window.open('http://google.com','_parent');">


Code:
<a href="http://ourbulgariaforum.com"><img src="http://i280.photobucket.com/albums/kk178/netsniperthefirst/biba.jpg"></a>

Bangernomics
Forumember

Female Posts : 144
Reputation : 1
Language : English
Location : UK

Back to top Go down

Solved Re: Need some code to enable new tab

Post by runawayhorses on January 31st 2013, 7:20 pm

Here you go, I needed to add the blank tag after the url of the site not the image, this will work for you now:

Code:
<a href="http://volkszone.com" target="_blank"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg"></a>

Here's your other link not sure which one you wanted:

Code:
    <a href="http://ourbulgariaforum.com" target="_blank"><img src="http://i280.photobucket.com/albums/kk178/netsniperthefirst/biba.jpg"></a>

runawayhorses
Hyperactive

Male Posts : 2537
Reputation : 162
Language : English
Location : United States

http://runawayhorses.alldiscussion.net/

Back to top Go down

Solved Re: Need some code to enable new tab

Post by SLGray on January 31st 2013, 8:08 pm

@Bangernomics wrote:
@runawayhorses wrote:You add a target="_blank" like this below:

Code:
    <a href="http://volkszone.com"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg" target="_blank"></a>

Tried this but it doesn't open in a new tab

Code:
    <a href="http://volkszone.com"><img src="http://i1299.photobucket.com/albums/ag78/Bangernomics/Red.jpg" target="_blank"></a>

@Bangernomics wrote:Can you tell me how I should add it to my code? sorry but its not clear to me and I know nothing about code


CJ11™ wrote:Hi,

Code:
<script type="text/javascript">window.open('http://google.com');</script>
Either that, or add target="_blank" to the originating link/form which landed in this "Photo Gallery Redirect" page.

Code:
<a href="http://google.com" target="_blank">click here</a>
or

Code:
<form action="http://google.com" target="_blank">
    <input type="submit" />
</form>

or
Code:
<meta http-equiv="refresh" content="5; URL=javascript:window.open('http://google.com','_parent');">


Code:
<a href="http://ourbulgariaforum.com"><img src="http://i280.photobucket.com/albums/kk178/netsniperthefirst/biba.jpg"></a>
Please don't double/triple post. Your post need to be separated by 24 hours before bumping, replying or adding more information. Please use the edit button instead!

Since this is your third reminder, you have received a warning.


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35622
Reputation : 2372
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

Solved Re: Need some code to enable new tab

Post by Bangernomics on January 31st 2013, 11:56 pm

Thank you Very Happy

Bangernomics
Forumember

Female Posts : 144
Reputation : 1
Language : English
Location : UK

Back to top Go down

Solved Re: Need some code to enable new tab

Post by SLGray on February 1st 2013, 1:03 am

Topic Solved & Locked


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35622
Reputation : 2372
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum