Jump to content

Can someone help me use SSI.php to let users access a web page


thirtywest

Recommended Posts

Greetings, 1st time posting.  Quite new with php.

 

I've been managing an SMF forums for about 6 months now. 

I have a few static pages in wordpress I'd like to make visible only to members.

I'm trying to use SSI to validate they're logged in before showing the pages.  But,

 

1. I'm having a tough time of that :), and

2. I can't seem to make it work from inside wordpress, and

3. If i have to build the pages from scratch I don't know if i'll have the features that I'm looking for; and

4. I just need a simple way to prevent folks from entering the URLs directly--only having access from being logged into SMF first.   I intend to build a button on the forum menu to take them to this expanded content page.

 

 

Am I asking too much?

 

ANY guidance would be greatly appreciated.

Link to comment
Share on other sites

A little googling tells me there is nothing simple that will let you do this SMF Wordpress integration.  SMF and Wordpress don't play well together, just looking at a few posts asking for something similar to what you want.

There are bridge hacks for SMF that will "pump" user accounts into wordpress.  These types of bridges are notoriously brittle, as changes to either side of the equation break them.  There's also the matter of lots and lots of wordpress accounts, when typically you only want a few for you to author with.

Another possible solution would be to protect the wordpress pages with a plugin like this one:  https://wordpress.org/support/plugin/password-protect-page/ although it does some hacking with the wordpress user system that might be problematic. 

Using that plugin you could possibly integrate with it, or you could hack your own solution.

In either case, it looks like the way to do it would be to write your own standalone php script that would utilize smf's SSI.php stuff to check authentication and grant access.   You could think of this as your own primitive SMF REST api.

You could call this from ajax you have in the wordpress page to allow or deny rendering of the wordpress content body.  This would get you around a lot of complexity issues.

While we do have a lot of PHP experts here, PHPFreaks hasn't personally used SMF in many years, although we did use it for a while, so I don't know that there is anyone active in the community that has much recent experience.   I'd suggest focusing your efforts over at the SMF forum.  Just be really clear about what you want to do, and how you intend to implement it.

 

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.