MyBB Community Forums

Full Version: Google Document MyCode
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
[Image: 16713-1313312734-2.thumb.jpg][Image: 16713-1313312718-1.thumb.jpg]

A simple MyCode which able you to embed Google Docs into your posts easily.

http://mods.mybb.com/view/google-documents

Manual Installation Wrote:Regex:
[gdoc](.*?)\[\/gdoc\]

Replacement:
<div class="codeblock"><div class="title">Google Document:</div><div class="body"><iframe src="https://docs.google.com/document/pub?id=$1" width="100%" height="300px"></iframe></div></div></div>

Google Document MyCode Wrote:Usage
-------
All you need is the ID. For example, these are the 3 links which can be found at the document you want:

- Editing the document
https://docs.google.com/document/d/1apveaUwdaYevtuVIb8Q1vp4VTxyEejc22TAHLhaPSYw/edit?hl=en_US

OR

https://docs.google.com/viewer?a=v&pid=e...true&srcid=1wvDPpnd0EcZWNSDX5kunKSKUjeQk-CwdmstCYX_SeJYDkO1zdb10-x4jR0tR&hl=hr

OR

https://docs.google.com/leaf?id=0B6g1fNYZpYWvMWEwZDA0MzMtZmY0NC00NzhkLWI3ZGUtNmI1NTQxMDliNTY4&hl=en_US

- Publishing the document
https://docs.google.com/document/pub?id=1apveaUwdaYevtuVIb8Q1vp4VTxyEejc22TAHLhaPSYw

And the tag is:
[gdoc]ID[/gdoc]
Doesnt work for me...

Does not work..nothing shows in firefox or IE. Set to public view a well.

http://www.bringit2u.com/forum/thread-5132.html
I have not been able to get it to work either. It would be exactly what I need if it can work. Thanks for the effort on the code anyways.
(2011-08-15, 10:15 AM)acrox999 Wrote: [ -> ][quote="Manual Installation"]Regex:
[gdoc](.*?)\[\/gdoc\]

Replacement:
<div class="codeblock"><div class="title">Google Document:</div><div class="body"><iframe src="https://docs.google.com/document/pub?id=$1" width="100%" height="300px"></iframe></div></div></div>

The replacement should be
<div class="codeblock"><div class="title">Google Document:</div><div class="body"><iframe src="https://docs.google.com/document/pub?id=$1" width="100%" height="300px"></iframe></div></div>

You had one too many </div> tags.
(2011-10-03, 11:09 PM)fizz Wrote: [ -> ]
(2011-08-15, 10:15 AM)acrox999 Wrote: [ -> ][quote="Manual Installation"]Regex:
[gdoc](.*?)\[\/gdoc\]

Replacement:
<div class="codeblock"><div class="title">Google Document:</div><div class="body"><iframe src="https://docs.google.com/document/pub?id=$1" width="100%" height="300px"></iframe></div></div></div>

The replacement should be
<div class="codeblock"><div class="title">Google Document:</div><div class="body"><iframe src="https://docs.google.com/document/pub?id=$1" width="100%" height="300px"></iframe></div></div>

You had one too many </div> tags.

what about me. :-)
Well if you used the same code...then yes you have the same problem.