Jump to content


- - - - -

IP.Board 2.3: Using a greybox to display pop-up boxes


  • Please log in to reply
53 replies to this topic

#41 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 26 February 2009 - 02:34 PM

View PostTom, on Feb 26 2009, 02:04 PM, said:

I can confirm, that it works to 100% now. Both - internal and external links can be managed by that way.


Now we should extend the tutorial to the IPB-internal popups e.g. bbcode and smilieys as well a costum template and of course - we need urgently it combinated with the attachement system. Opening Imgages in greybox would be an excellent improvement as well a bbcode which could be used for.

I think at this point I will pause for a cup of coffee  ;)  then update the tutorial.

I have left a reply for Michaeljohn about his tutorial on creating a php page which I hope to use for the My assistant (my next progression).

personally, I would avoid the attachment system like the plague, it is notoriously hard to work with. Opening images with greybox would be nice, but the IMG tags are buried in code somewhere and are not easy to work out, well for me anyway.

I am glad it now works for you :)

regards

Richard

PS - in the meantime,  if you want to develop new usage and add 'how-to' details to this thread I will add them to the tutorial and credit you :)

#42 Tom

Tom

    Posting God

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 1,541 posts
  • IPB Version:v2.3.x

Posted 26 February 2009 - 03:24 PM

Sure

++++++++++ ++++++++ add-on for RichardC Greybox Tutorial +++++++ +++++++++
~~+~~~+~~ should be used just by webmasters where the forum is not located in server root ~~+~~~+~~

Example 1:
Domain: www.my-domain.com
forum root is:/
forum URL www.my-domain.com (=same like invisionmodding

Example 2:
Domain: www.my-domain.com
forum root is:/community/
forum URL www.my-domain.com/community/

Our Manual is for installation of Greybox for example N# 2
1.
1.1 Create a folder in /community/ - > call it 'greybox'
1.2. Put into the folder the 'greybox' the js + css files from the greybox.zip you have dl from the developer
the path must look like
/community/greybox/

and the folder 'greybox' must contain the following files
AJS.js
AJS_fx.js
gb_scripts.js
gb_styles.css


2.
Go to LOOK & FEEL => Edit the Board Header and Footer Wrapper

add code directly below the <head> tag

<!--Start greybox Code-->
<script type="text/javascript">
var GB_ROOT_DIR = "http://my-domain.com/greybox/";
</script>
<script type="text/javascript" src="http://my-domain.com/greybox/AJS.js"></script>
<script type="text/javascript" href="http://my-domain.com/greybox/AJS.js"></script>
<script type="text/javascript" src="http://my-domain.com/greybox/gb_scripts.js"></script>
<link href="my-domain.com/greybox/gb_styles.css" rel="stylesheet" type="text/css" />
<!--End greybox Code-->

3. Go to LOOK & FEEL =>  Edit Template HTML =>  All Global HTML => global_board_header

Find:
<!--ipb.rightlinks.start-->

add below
<div class='ipb-top-right-link'><a href="http://www.google.com" onclick="return GB_showCenter('Google', 'http://www.google.com',630, 750)">Launch Google</a></div>

Note: You can customize the dimension by editing the variables height and width 'http://www.google.com',630, 750)">

++++++++++ ++++++++ add-on for RichardC Greybox Tutorial  End +++++++ +++++++++

#43 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 26 February 2009 - 03:41 PM

Tom, can you temporarily rename your folder /community/greybox/ to something else eg:  /community/tom-greybox/
and tell me if the greyboxes still work? - Im hoping that the last edits done to your header and footer wrapper mean the 2nd greybox folder is no longer needed.

#44 Tom

Tom

    Posting God

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 1,541 posts
  • IPB Version:v2.3.x

Posted 26 February 2009 - 03:49 PM

View PostRichardC, on Feb 26 2009, 10:41 AM, said:

Tom, can you temporarily rename your folder /community/greybox/ to something else eg:  /community/tom-greybox/

*done*

View PostRichardC, on Feb 26 2009, 10:41 AM, said:

and tell me if the greyboxes still work? - Im hoping that the last edits done to your header and footer wrapper mean the 2nd greybox folder is no longer needed.

The folder is required, for any reason.
At last I left one in the root and one in the /community/ folder

#45 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 26 February 2009 - 04:36 PM

View PostTom, on Feb 26 2009, 03:49 PM, said:

View PostRichardC, on Feb 26 2009, 10:41 AM, said:

Tom, can you temporarily rename your folder /community/greybox/ to something else eg:  /community/tom-greybox/

*done*

View PostRichardC, on Feb 26 2009, 10:41 AM, said:

and tell me if the greyboxes still work? - Im hoping that the last edits done to your header and footer wrapper mean the 2nd greybox folder is no longer needed.

The folder is required, for any reason.
At last I left one in the root and one in the /community/ folder

this is what I am trying to ascertain, if you renamed your folder  /community/tom-greybox/ and it all still works, then that folder is no longer being referenced and is no longer needed.
so, having renamed the folder, does it all still work? if yes, the folder is not needed, if no, then the folder is still needed

Rich

#46 Tom

Tom

    Posting God

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 1,541 posts
  • IPB Version:v2.3.x

Posted 26 February 2009 - 05:04 PM

The folder is needed. Renaming it produce a strange loop. It opens an iframe within the existing page.

#47 Guardsman

Guardsman

    Coder

  • IM Supporters
  • PipPipPipPipPip
  • 246 posts
  • IPB Version:v2.3.x

Posted 26 February 2009 - 07:47 PM

View PostRichardC, on Feb 25 2009, 10:43 PM, said:

ok, try leaving the greybox folder where it is with all the files in and add a NEW greybox folder in your server ROOT directory
http://www.mydomain.co.uk/greybox/

and change your root path
	var GB_ROOT_DIR = "http://www.mydomain.co.uk/greybox/";

the code author was quite specific that the files should be in your ROOT directory, but as Tom has discovered, some paths also require files in your forum root.

do those 2 changes and let me know if you get any functionality

Not sure why you asked me to do this because I seem to have a fully functioning greybox with my current config  ;)

Anyway, I did that (exactly as you requested) but my links wouldn't open. The greybox windows open but they remain on the 'loading' animation (both internal links and the example google link).

Changing my var GB_ROOT_DIR back to my forum root fixed the problem - links now working (again).

Hope that helps!
Nobody reads this bit...

#48 Tom

Tom

    Posting God

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 1,541 posts
  • IPB Version:v2.3.x

Posted 28 February 2009 - 01:24 PM

So can we talk about further greybox opportunities e.g. linking to IPB-internal popups? Who is willing to assist e.g. bbcode-popup and smiliey window?


I'm working on a bbcode which opens thumbnails in a greybox.

#49 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 02 March 2009 - 10:50 AM

View PostTom, on Feb 28 2009, 01:24 PM, said:

So can we talk about further greybox opportunities e.g. linking to IPB-internal popups? Who is willing to assist e.g. bbcode-popup and smiliey window?


I'm working on a bbcode which opens thumbnails in a greybox.

I dont have any issues using this thread for any greybox opportunities, if a piece of code works it can be added to the general turorial, if things start to get too messy we/you/me/whoever can always write a seperate greybox tutorial specifically for a certain modification

regards

Rich

#50 kay1021

kay1021

    n00b

  • Members
  • Pip
  • 1 posts
  • IPB Version:v3.0.x

Posted 06 April 2009 - 04:38 AM

I'm kinda new to using jquery and such...i understand it somewhat but
i've hit a bit of a snag.

I have a gallery that i wanted to use the greybox with as it's the
only lightbox type deal i could find to work with my other code...that does allow outside
webpages  (i.e
google).

However the first item on the page it will open correctly (in greybox)
but then
when you click on another item it won't open in the greybox it opens
in a new page. I think it might be because the different images in my
gallery add a "#2" or whatever image is it to the end of the
address....but you haven't really
changed pages it's just to deal with history so that if you click the
back button on your browser it just got back to "#1" instead of a
whole other page.

I'm wondering if anyone might know how to fix this or get around it.

I'm really hoping this will work as i said this was the only one i could find to work with my other code.

Thanks!

#51 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 06 April 2009 - 08:08 AM

I seem to remember that there are specific issues to do with opening a second link from within the greybox. You really need to search in thier google forum as I am sure there have been solutions posted there.

If you are using greybox for images, you could also take a look at : http://highslide.com/ which is very good for images.

There is a topic here: http://www.devfuse.c...h...ic=2429&hl= which deals with making it work automatically with the IPB attachment system. I cannot repeat the information here as the topic's author has requested that the solution is not made publicity available. If you cannot see the topic after registration, I'm afraid there is not much I can do

regards

Richard

#52 Tom

Tom

    Posting God

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 1,541 posts
  • IPB Version:v2.3.x

Posted 06 April 2009 - 09:03 AM

View PostRichardC, on Apr 6 2009, 03:08 AM, said:

which deals with making it work automatically with the IPB attachment system. I cannot repeat the information here as the topic's author has requested that the solution is not made publicity available. If you cannot see the topic after registration, I'm afraid there is not much I can do

Cool stuff Richard! Thanks for the note.


Btw. do you using Google Chrome? With all browsers my greybox works but not with G!Browser.

#53 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 06 April 2009 - 09:24 AM

sure thats not a javascript setting within chrome itself? works ok for me in FF3, IE7 and Chrome

#54 ranjani

ranjani

    Advanced Member

  • Members
  • PipPipPipPip
  • 61 posts
  • IPB Version:v2.3.x

Posted 14 April 2009 - 06:16 PM

please check this and could you provide a fix please ...  

when we use greybox code for My Friends
[java script:friends_pop()] PM friend link is not working ;)

when it was a pop-up the PM page comes through the original
webpage from where we click My Friends Link .

Thanks

Edited by ranjani, 14 April 2009 - 06:19 PM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users