![]() |
|
Thread Tools |
#1
|
||||
|
||||
Userid in PHP-Module
I've extended user profile site with a PHP-Module, which includes a php file. In this file I need to compare two variables.
First variable is userid from user, who visits the profile. Second is whos profile you watch. In my script, second variable is empty. How can I get access to user profiles userid in my included PHP-Script? --------------- Added 01 Feb 2019 at 17:05 --------------- Frustrating. No members have liked this post.
Last edited by BulliM; 01 Feb 2019 at 11:52. Reason: Found out, page['userid'] is the right name |
#2
|
||||
|
||||
The userid of the profile being viewed is not available in the $vbulletin variable. Just extract and parse it from the current profile URL.
__________________
Glenn Vergara, an ex-vB Developer, now a vB Mod Developer ![]() GIPHY for vB5 | AutoLinker | Video Attachments Player | New Registered Users Module | Clear System Cache Cron | DragNDrop Upload | Topic AJAX AutoUpdate | Force Read Topic No members have liked this post.
|
#3
|
||||||||
|
||||||||
Originally Posted by noypiscripter
Nice solution.![]()
Because profile userid is available in $vbulletin->scriptpath, my solution was:
Kind of the same way, but also differently. No members have liked this post.
Last edited by BulliM; 03 Feb 2019 at 07:25. |
#4
|
||||
|
||||
What does scriptpath return? Can you give an example?
__________________
Glenn Vergara, an ex-vB Developer, now a vB Mod Developer ![]() GIPHY for vB5 | AutoLinker | Video Attachments Player | New Registered Users Module | Clear System Cache Cron | DragNDrop Upload | Topic AJAX AutoUpdate | Force Read Topic No members have liked this post.
|
#5
|
||||
|
||||
/member/123-username
No members have liked this post.
|
![]() |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Add-On Releases Subscribed/Favorite Forums Module [vba CMPS module] | Skedoozy | vBulletin 3.6 Add-ons | 17 | 13 Apr 2008 15:25 |
Module CMPS: Custom Welcome module | corn dog | vBulletin 3.5 Add-ons | 8 | 02 Jun 2006 18:10 |
«
Previous Thread
|
Next Thread
»
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
|
|
New To Site? | Need Help? |
All times are GMT. The time now is 00:13.