![]() |
Joel,
Sure, my g2 and vb are in separate folders-- the trick is that global.php sets up CWD as the current working directory-- and if you are calling/including global.php from outside of the vb directory you have a problem. I made a change to global.php: Code:
if( !defined(CWD) ) { Code:
define('CWD', '/var/www/html/vb'); Code:
require_once('/var/www/html/g2/embed.php'); Also, I've noticed that if you are including vb SIMPLY so you can use $vbulletin->userinfo['userid'] to pass into g2, you do not seem to need to include vb/global.php, you can include vb/includes/init.php instead-- it's faster as it doesn't load up a bunch of stuff not needed. Another side note. If you want to make sure that accessing g2 pages keeps the vb session alive, include the vb stuff as mentioned above, but also make sure to call exec_shut_down() near the end of your script-- this makes vb flush out the session to the db, which then keeps the session alive. I should note though that I'm not using the vb templating system (fetch_template('gallery2')) to accomplish my display (as this thread discusses). Instead, I simply take the output from the runGallery() call and embed it directly in html in the same script. My script ends up looking like this (obviously pseudocode): Code:
set THIS_SCRIPT Also, this works in 3.6.6, 3.6.7 and 3.6.7 PL1 Before you ask me a question, make sure you read this whole thead, cause if you ask something dumb that can be answered by looking at the code or reading this thread like 'what do you mean by set THIS_SCRIPT' or how do you do 'set THIS_SCRIPT, I will ignore you. Think before you ask. Next.... Looks to me like file access permission errors. Maybe your webserver can no longer can write to your g2data directory? Your last error leads me to believe your plugins have a path to your embed.php file and embed.php is no longer where it should be. Look at the paths in the errors and figure out what it's complaining about-- it's all there. Quote:
|
Alright,
Before I attempt using the unembeded version I thought I would try the mod first. http://www.appozone.com/test/gallery.php Looks like for some reason it includes /test/test/ twice and thus does not display any images. Any advice appreciated. Regards, .Joel |
i know this isn't a solution for all..but this integration never seems to be solid.
you are better off going with vbdrupal and integrating gallery..I do this on my site with no problems with full group synch between platforms. |
cool hack
|
Quote:
|
anyway to set up access to only admins and super & general mods and have a second gallery for everyone to post into?
and will this work with vb 3.6.7 and gallery 2.2.2?? |
Basically, all the ideas here are valid for 3.6.X. I'm running 3.6.7 PL1 (uh, as I meantioned above), and Gallery 2.2.1 (although I've looked at the change list for 2.2.2 and I don't see much that would effect it except for the Download image rewriting fix, but thats pretty narrow and only valid if you are using main.php for core.DownloadItem).
Quote:
|
hmmmm, i dont understand what it is that i am doing wrong. when i try to visit gallery2.php its loads up completely empty.
i followed the installation closely, but it doesnt work. i have it set up as ...site/forum & ...site/forum/gallery2/ |
Quote:
This tutorial doesn't clarify the correct dir for embedding gallery and vb My structure is this ...site/forum>vbfiles & ...site/forum/gallery2/>gallery2 files The template loads but my images think there at ....site/forum/forum/gallery2 I cant seem to find a way to fix it... :mad: |
hello to all
i followed the installation instructions and installed gallery 2.1.1, the program installed properly, everything is working as expected, except the navbar links from vbulletin do not show up, as a standalone product the gallery works fine, it also works as a forum link . I am running vbulletin 3.5.4, the url to the site is http://www.freemovie-downloads.net/gallery2/main.php I have spent over two days trying to figure out what is not working. I cant get gallery2 to be embedded as part of vbulletin. I need some input as to what can be wrong. vbulletin is in /httpdocs/forum gallery2 is in /httpdocs/gallery2 gallery2.php is in /httpdocs/forum gallery2.php PHP Code:
|
For those that are getting the following error:
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING It has been said before on page 4, but what you need to do is fix an error in the upload plugin. Go to plugin manager > Update Gallery User and edit the following line: Code:
require_once('/home/website/root/forum/gallery2/embed.php''); Code:
require_once('/home/website/root/forum/gallery2/embed.php'); |
I'm having the problem like oldgoat above. I have installed G2 into my vbulleting forums directory. All seems to work, but there are no buttons in the navbar. If you manually browse to the gallery2.php page it's there. I thought maybe it was my skin, but looking at the "more" stock skin, I still dont' see anything in the navbar. I don't even know what to type to get someone started in helping me, sorry. But any help would be much appriciated!
Andrew also, we're randomly getting the error: unexpected T_CONSTANT_ENCAPSED_STRING If I remove the double quote as stated above, we cannot post or send PMs at all. We get: Warning: Unknown(/forums/gallery2/embed.php): failed to open stream: No such file or directory in /includes/class_dm_user.php(1657) : eval()'d code on line 1 Fatal error: (null)() [function.require]: Failed opening required '/forums/gallery2/embed.php' (include_path='.:/usr/local/lib/php') in /homepages/42/d98622539/htdocs/terraforums/forums/includes/class_dm_user.php(1657) : eval()'d code on line 1 Thanks very much :) |
wouldnt it be good to release a new version of the integration working for 3.6.8 to cut all those discussion short and makes it easier for people to find the right answer.
im still confused if i just download this integration and leave it as it is, or if i have to edit it after? |
or better release a mod/plugin for this :)
|
When I run this mod, I receive the message:
Code:
Warning: require_once() [function.require-once]: open_basedir restriction in effect. File(/public_html/forum/gallery2/embed.php) is not within the allowed path(s): (/home/outrack/:/usr/lib/php:/usr/local/lib/php:/tmp) in /gallery2.php on line 55 Is there anyway to get past this without having to contact my host to remove the open_basedir restriction? |
i got it working to a point that it's showing the header, albums, footer, etc. but it's not taking into account the css. so the albums are all over.
where is a good place to declare the css? tia! |
So, I decided to take a fat chance and try installing Gallery 2.2 (Latest) with vBulletin 3.6.8, and lo and behold it worked. Well, almost.:cool:
Here's what I did: I created the gallery2 directory within the forum home, as indicated. But then I struck a small problem. The "Your album" as well as clicking on an image, would take me to /v/<name>.:confused: So, I then proceeded to move gallery2.php to /gallery2/gallery2.php, (didn't need to change the embed.php line or anything) and nothing came up. I then linked the file back to gallery2.php and it worked. :D No snags yet. (See minor issues below.) I did try and add the .xml files for the two addons, and also hit a serious snag.:erm: Trying to add it as a product said this looks like a Plugin... Ok, so now to add a plugin. And I had to do a quick crash course. So here goes for those that don't want to do too mouch soul or web searching: In the add new plugin part:
I am still trying to figure out, how to not pass the gallery out of the vBulletin forums, when you click on "My Gallery" and any images. This however is not a major issue right now, as I will change the skin to allow you to go back to either the home page or the forum anyway. Thankyou for all the work Brent. Well done. Now I need to figure out how to do a group control from vBulletin to gallery, whereby only members of a specific forum group can add images to the gallery. |
VBB - 3.6.8
vBadvanced CMPS - v3.0 RC2 Gallery - 2 http://www.soft.com.sg http://www.soft.com.sg/forum http://www.soft.com.sg/gallery http://www.soft.com.sg/forum/gallery.php Hi guys I have set up as above but somehow I could not get the integration working. The forum(with CMPS) and gallery are working fine on their own. Please help me out here. Thanks. James <?php // ####################### SET PHP ENVIRONMENT ########################### error_reporting(E_ALL & ~E_NOTICE); // #################### DEFINE IMPORTANT CONSTANTS ####################### define('NO_REGISTER_GLOBALS', 1); define('THIS_SCRIPT', 'gallery'); // change this depending on your filename // ################### PRE-CACHE TEMPLATES AND DATA ###################### // get special phrase groups $phrasegroups = array( ); // get special data templates from the datastore $specialtemplates = array( ); // pre-cache templates used by all actions $globaltemplates = array( 'gallery', ); // pre-cache templates used by specific actions $actiontemplates = array( ); require_once('./global.php'); $navbits = array(); $navbits[$parent] = 'Gallery'; error_reporting(E_ALL ); $navbits = construct_navbits($navbits); eval('$navbar = "' . fetch_template('navbar') . '";'); $data = runGallery(); $data['title'] = (isset($data['title']) && !empty($data['title'])) ? $data['title'] : 'Gallery'; function runGallery() { global $vbulletin, $userinfo; require_once('/hsphere/local/home/jameswoo/soft.com.sg/gallery/embed.php'); $data = array(); // If it's an anonymous user, set the g2 activeUser to null $uid = $vbulletin->userinfo['userid'] = 0 ? '' : $vbulletin->userinfo['userid']; $ret = GalleryEmbed::init(array('embedUri' => '/forum/gallery.php', 'g2Uri' => 'http://www.soft.com.sg/gallery/', 'loginRedirect' => 'index.php', 'activeUserId' => $uid)); |
@softsingapore, try using the html code (step 2) from this thread :
https://vborg.vbsupport.ru/showthrea...ry+integration i had the same problem like you where it showed a blank page. below are my declarations. compare it to yours and see if it will help. Quote:
|
anyone figure out how to include group sync?
|
Does this allow the VB users username and passwords to be transfered over too, so users don't need to create a new account to upload pictures?
|
Yep. The script Carbon-copies the user's account to the gallery when the navigate to the integrated gallery page.
Also, I'm trying to use this in vB3.7, but http://www.alteranlabs.co.uk/forums/gallery2.php is screwed up; None of the images are there and the formatting is out-of-whack. I've looked at the image path for the placeholders, and it's done "/forums" twice! Any way to rectify this? |
I tried this integration with Gallery 2.2 i got this error message:
Quote:
|
Alright, new to vbulletin and this is the first site that I've used it with. I decided to go the way of using gallery2 with my vB install and got this entire integration to work properly.
My setup is as follows in case you need to know: hswaves2008/forum/(forum files) hswaves2008/forum/gallery2.php hswaves2008/forum/index.php (the default file with vbulletin) hswaves2008/gallery/(gallery files) hswaves2008/index.php (the vbadvanced CMPS file) My gallery2.php code: PHP Code:
Now, the problem that I am having is this. 1) Click on the image that I uploaded t the gallery. (its the only one there) 2) If you scroll down to where it says "Photo Properties", just under that is an option to click on DETAILS. If you click this link to see more details on the image, the link is broken. Is there something that I need to do to get these links working properly. I have read this thread through several times and finally got the gallery2.php file working and searched through a couple more times for this issue and to no avail, I have found nothing that addresses this issue. Or maybe I don't know what solution I should be looking for. Any help here would be greatly appreciated. BTW... I have to say that vBulletin far surpasses any other forum/CMS that I have ever used in the past. I love it and it has been user friendly since day one. Now, tojust get this integration to work properly. Thank You. |
Quick question - does the G2 database need to be in the same database as vB?
I will be starting from scratch on this. I have an existing vB 3.6.8 installation. No Gallery2 at all currently. I am not currently convinced I need to embed. In fact I am leaning away from it for the simple fact that my forums are a fixed width right now. Letting the galleries break out will up the available width by about 250px. I do however need to unify logins for users. I'd also like to have links to user's galleries in their profiles. As for Gallery2 version, it sounds like 2.1 will be a bit less painful to get up and running with vB 3.6.8. Is this assumption correct? |
It has been a few days since I have seen a response. I have tried emailing and PMing a few of the users that responded and seemed proficient in correcting issues with this integration. I have it working and just need one little tweak to get some links working but it doesnt seem like this is supported anymore. No one checks this thread and the last few posts have seen no responses. The last support response was a month or two ago. Anyone out there that can help? Please?
BTW, I have Gallery 2.2 and IB 3.6.8 and it works just fine. The only issue that I am having is the one listed above. I am sure it can be corrected because I have seen a site in action with these two versions. Just waiting for a response from one of the users here. Hope they can help. |
I sort of gathered that.
Maybe you can answer my question about the db since yours is up and running. Did you install G2 to your vB database or are they separate? Does it matter either way? I looked at your site earlier and the details link wasn't pointing to your forum folder - it was formed as if the folder was in the doc root. I just looked again now and the details link worked for me. |
I figured it out last night and it is working for me now. I had one thing set wrong in my gallery2.php file. Looking through this thread over and overhelped me a lot even after I had already looked and looked through it man times a day until I had it right. Here is how you set it up.
install vbulletin to: domain.com/forum/ install gallery to: domain.com/gallery/ open up a text editor and insert this code: PHP Code:
Save this file and upload to: domain.com/forum/gallery2.php Create the new template like Step 4 of the initial post instructs you to do. That is all. Now you can use the gallery2.php file as the link to your gallery. You will need to edit the css file in gallery to match the colors of your vbulletin or vice-versa. What this code does is integrate the gallery and the forums when anyone visits that file. When they register for your vbulletin forum, it WILL NOT create a gallery user yet. The user must first visit the gallery2.php file in order for a user account to be created in gallery. As I understand, there are two different db's. One for vbulletin and one for gallery. The password for the gallery will not be the same as the vbulletin forum for the user due to the fact that vbulletin wants to add SALT(password) to the password. When a user visits the gallery2.php file for the second time it will look to see if the user is registered in vbulletin and if so, will look in the gallery db for a user account that matches,and if so then all will be gravy. If you have any further questions, let me know. Im not good at this stuff but if you follow my instructions, it will work now that I have it all figured out. It just sucks that someone like me has to be support for this for the fact that Im not really good at this stuff and am new to all this coding. Im a first timer to vbulletin, even if I have installed quite a few things in the past. I really would like to know what I am talking about when I help someone. What kind of code do I need to know to tweak this stuff. PHP? If I got a book on PHP, would that help me? |
Thanks man! That is all easy stuff.
I am still unsure about my original DB question though and haven't seen an answer. I ASSume it doesn't matter where the vB database is in relation to the Gallery2 database because it is looking at that globals.php file which best I can tell pulls the user info from the vB database regardless of where it is - it knows where to look. My question stems from Joomla and the fact that all of the vB integration features for it require the vB database to be installed within the Joomla database and I like to keep things separate. Chances are, if you did not specifically create a new database for your Gallery2 install, then it dumped it into the vB database. I think what I will do is just try it with Gallery2 in it's own database. If it doesn't work I am out about 20 minutes of time and it is easy to clean up. I'd rather start there and integrate them later if I need to than integrate them and then have to go back later and correct it. --------------- Added 17 Feb 2008 at 14:48 --------------- Ok all I am getting is the white screen. Install paths are as follows: /chroot/home/mazdaoca/mazdaoca.org/html/community/global.php /chroot/home/mazdaoca/mazdaoca.org/html/community/gallery/embed.php Installed in the following: vB: webroot/community/ G2: webroot/community/gallery/ URL I am using is: http://www.mazdaoca.org/community/gallery.php The direct G2 link works fine: http://www.mazdaoca.org/community/gallery/main.php VB template "gallery2" has been created and the "head" section contains the code posted in Step 4 of the instructions. gallery.php is as follows: Code:
<?php Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
The infamous white page is due to the fact that your php file is not configured properly. You installed your gallery within the forum directory. It has been specified that you need to install the gallery in the root directory of your domain. The first post f this thread is confusing. They state that you need to put the gallery in the root of your vbulletin and then go to say later that the root of your vbulletin is up a directory from the forum folder. If you wish to keep the setup you have now then I believe you need to add something here.
PHP Code:
As for your other question, sorry I didn't understand what you were asking the first time, but yeah, I have two db's one for the vbulletin and one for gallery. They are linked through the gallery2.php file. |
I never saw a post saying it needed to be up a folder, just that it needed to be in my forum root (not webroot).
If I move it up into the webroot then my paths will need to be corrected. |
Sorry if it wasn't clear. I have my site set up like this:
hswaves2008/forum/(forum files) hswaves2008/forum/gallery2.php hswaves2008/forum/index.php (vBulletin's default index) hswaves2008/gallery/(gallery files) hswaves2008/index.php (the vbadvanced CMPS file) I can vouch that it works with this set up. Check the other posts in this thread, most everyone else has the same setup. |
Yeah that is how I am doing it now. Re-uploading the G2 folder as we speak.
I'm not running vbadvance but best I can tell that doesn't matter. This just looks at vB through the globals.php file. --------------- Added 17 Feb 2008 at 19:56 --------------- Ok I give up. I tried it 3 times. I am now using your exact structure and exact config.php (updated for my paths) and I am still getting the white window of death. It is working to an extent. When I try to go to the embeded gallery link nothing happens but if I log into the gallery2 installation my vB username is carried over. I tried logging in with it though and it kicked me out. Either I am screwing something up with the template or there is an issue in the newest version of G2. --------------- Added [DATE]1203300302[/DATE] at [TIME]1203300302[/TIME] --------------- Ok I got it working. I was creating a new "style" and not a new "template". Next question - how do I set it up so users can create their own galleries - or is this some functionallity that isn't part of this? I assume it is because there would be no need to pull user info if the only purpose of this was to embed G2 in the vB page. |
there is apparently some code within this thread that puts the private album link in each persons profile. You will need to look for it. Before you do this, I would assume you'd just need to enable private albums for registered users in the gallery.
This is one function that I probably won't install on my site but if you figure it out, it would be nice if you post your solution for those who may look here later for help. |
Yeah I found al that stuff but I am back to getting the white screen of death - and I didn't change anything. It is exactly how it was when it was workig and all of a sudden it just stopped.
:rolleyes: I am gonna wipe it out and try it 1 more time. --------------- Added [DATE]1203369864[/DATE] at [TIME]1203369864[/TIME] --------------- Ok I finally got it all working. I figured something out - the order in which you do things MATTERS. Every edit to every file needs to be done BEFORE you hit your trigger link for the first time. Basically my final process (which worked) consisted of:
Now that it is up and running it does integrate very well. I am going to have my site staff test it for a little while and then I will release it to the masses but if my brief tests are any indication - this is a very workable option for a vB image gallery. The thing I like the most about it is that it installs and uninstalls without touching anything in vBulletin (other than adding the plugins and template which come out easy enough). I went through the entire process 3 or 4 times so I am familiar with its removal as well. ;) So for reference, here is another working install to add to the list of demos: http://www.mazdaoca.org/community/gallery2.php |
I've been trying to get this integrated for the past day, and can get it integrated with vB, to the point it creates the user in Gallery2, and displays the gallery within vB.
However that's as far as I can get. I think my problem is something to do with how the Gallery 2 permissions are set-up, but I'm not sure how they should be set-up. I have tried setting up a 'User Ablums' album, and then setting additional permissions, but the permissions then apply to all subalbums. Can anybody give me a few pointers on how to get past this final hurdle? I'm running G2.2, with vB 3.6.8 and vBa CMPS v3.0.0 |
Finally got the user album issue sorted, although I'm still not sure it's working how it's intended (users can create new albums within the defined User Albums album, but they're not created automatically).
The problem turned out to be a problem with the User Album plug-in, but uninstalling, then reinstalling it seems to of cured things. For anybody looking to install from scratch, I'd advise you install gallery2, set-up a test user, and check the test user can create albums and upload before trying to integrate. I now just need to sort the link problem, which is causing page not found errors. |
Is this still alive? How can i integrate just the gallery and vbulletin logins (user table)?
|
The problem I am having with this and this seems to be the last problem I am having is that when a user is on the gallery2.php page, the popups for private messages dont appear if a user has a message. When they click on Options to get the expandable menu, the menu doesn't expand. There are certain features that dont work only in the gallery2.php file. They work fine on the rest of the site. Im guessing there is something missing from the gallery2.php file that allows for the full functionality of the site. Maybe someone can shed some light on my problem.
|
I had this working with gallery 2.0b4 with the old integration scipt... I've just upgraded gallery to 2.2 and have tried every possible combination of variables in the php file and I get nothing but the white screen!!
my setup:- /forum/(forum files) /gallery2/(gallery files) /forum/gallery2.php My variables (currently, as I've tried 1000 different combinations of relative and absolute paths here):- Code:
$ret = GalleryEmbed::init(array('embedUri' => 'gallery.php', |
All times are GMT. The time now is 04:45 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|