Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Geek Culture / youtube embedding, links not working, and code highlighting

Author
Message
Neuro Fuzzy
16
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 29th Jul 2011 09:43 Edited at: 31st Jul 2011 06:13
To Embed a Youtube Video

Lets say you want to embed this video:
http://www.youtube.com/watch?v=DH0BQtwEAsM
notice that on the end, there's a variable v="DH0BQtwEAsM". take that value, and put it in between two [youtube][/youtube] brackets. So this bbcode:
[youtube[/b]]DH0BQtwEAsM[/youtube[b]]
creates this:



How to add syntax highlighting to code snippets

http://forum.thegamecreators.com/?m=forum_view&t=161402&b=2

do this by adding an attribute to the [code[/b]][/code[b]] tags. So, if you wanted to highlight dbpro code, then you would say:

[code lang=dbp[/b]]
CODE HERE
[/code[b]
]


If you wanted to highlight some C++ code, then you would change that argument to "c".

[code lang=c[/b]]
int a=1; int pa=&a;
[/code[b]
]



Why some links don't work


Someone recently had trouble embedding this link:
http://www.play.com/Electronics/Electronics/4-/11719414/Apple-iPod-Shuffle-4GB-Pink/Product.html?_%24ja=tsid:11518|cat:11719414|prd:11719414

The issue there is the %24 sign. that's an html character code. if we look at this site, one can see that "%24" (it's hex, not decimal) is the $ sign. So if we change the link to this:
http://www.play.com/Electronics/Electronics/4-/11719414/Apple-iPod-Shuffle-4GB-Pink/Product.html?_$ja=tsid:11518|cat:11719414|prd:11719414

then it embeds fine:



[edit] hah spoke too soon. hmmmm.... well that's USUALLY the problem.[/edit]



...just sayin'


Why does blue text appear every time you are near?
TheComet
16
Years of Service
User Offline
Joined: 18th Oct 2007
Location: I`m under ur bridge eating ur goatz.
Posted: 29th Jul 2011 09:57
Or you can paste your link into Tiny URL and then post the link from there in your post.

Finally someone made a post to clarify all of this, I shall use the link to this post as my weapon against the noobs.

STICKY!

TheComet

bitJericho
21
Years of Service
User Offline
Joined: 9th Oct 2002
Location: United States
Posted: 29th Jul 2011 13:09
Quote: "Or you can paste your link into Tiny URL and then post the link from there in your post."


Don't use tinyurl. We can handle big links. I can find links again 10 years down the line. I won't be able to find tinyurl links 10 years down the line.


Ocho Geek
16
Years of Service
User Offline
Joined: 16th Aug 2007
Location: Manchester, UK
Posted: 29th Jul 2011 16:58
10 year old internet is a mysterious place


Not Spanish, Not Eight, Just Ocho

bitJericho
21
Years of Service
User Offline
Joined: 9th Oct 2002
Location: United States
Posted: 29th Jul 2011 17:21
Quote: "10 year old internet is a mysterious place"


Now think about 10 year old internet fulled up with bit.ly links. It makes me shutter :S


Neuro Fuzzy
16
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 30th Jul 2011 04:31 Edited at: 30th Jul 2011 05:46
CLICK IT. I DARE YOU:
http://tinyurl.com/3gtlyn8

(errm, it's a link that the mods get angry whenever someone posts it, but hopefully they wont notice this time [although I know it's their duty to investigate all links]. Please, click.)


Why does blue text appear every time you are near?
Indicium
15
Years of Service
User Offline
Joined: 26th May 2008
Location:
Posted: 30th Jul 2011 04:32
Damn you fuzzy! Damn you!

BMacZero
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: E:/ NA / USA
Posted: 30th Jul 2011 07:08
You pretty well counter-reverse-psychology-rickrolled me right there, Neuro .

_Pauli_
AGK Developer
14
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 31st Jul 2011 03:49 Edited at: 31st Jul 2011 03:50
Unfortunatly the

Quote: "code lang=cpp"


never worked for me!
I have no clue why...

Test:



Neuro Fuzzy
16
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 31st Jul 2011 06:13 Edited at: 31st Jul 2011 10:51
whoops... my bad... with some research apparently only "c" works.

so do

[code lang=c[/b]]
void TheFunction( bool Param )
{
// bla bla bla
400 + 20 = 420;
}
[/code[b]
]

:



Why does blue text appear every time you are near?
_Pauli_
AGK Developer
14
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 31st Jul 2011 21:03
Hey cool, thanks for the hint!

Login to post a reply

Server time is: 2024-04-28 04:40:00
Your offset time is: 2024-04-28 04:40:00