TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,963
  • Latest: BiZaJe
Stats
  • Total Posts: 195,917
  • Total Topics: 21,308
  • Online today: 790
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 428
  • Total: 428

[Block] Custom Page

Started by Thurnok, August 09, 2006, 08:13:37 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Thurnok

Woops... sorry, missed that you were using IE.  I checked with IE and I see the button is not working.  Must be the <button> tag has a problem with IE.  Checking it now.

Thurnok

Ok Roarin... I've got it fixed for you this time.

I used the <button> tag originally because I planned to use its extra features but ended up never using so changed it to a simple <input> tag.  IE is now all happy go funky.

Try it out and see if it resolves your issue.  :)

RoarinRow

Quote from: Thurnok on August 21, 2006, 07:17:01 AM
Ok... I found the problem.  This is what we call, fixing one problem and creating another ;)

When I modified for backward compatibility regarding HTTP REFERER I created the issue where if you put the code in an article that was not shown on the frontpage, you could not add a custom page because it reloaded index.php without your article showing (in otherwords, no page=<pagenum>).   So your non-frontpage article wasn't reloaded and hence the code to ADD was never executed.  heh

Ok, code updated.. give it a shot now.  :)

When I type in http://www.yahoo.com and click on the 'Add' button, I get this error:

The page cannot be found
The page you are looking for might have been removed, had its name changed, or is temporarily unavailable.

--------------------------------------------------------------------------------

Please try the following:

If you typed the page address in the Address bar, make sure that it is spelled correctly.

Open the www.avalanchestyle-test.com home page, and then look for links to the information you want.
Click the  Back button to try another link.
Click  Search to look for information on the Internet.



HTTP 404 - File not found
Internet Explorer

::)  At least it doing something this time, thanks. 

SMF 2.0 RC3
TP 1.0 beta 5-1
Wordpress 3.0

Thurnok

Did it create an entry in your database?
Clear your forum errors via the SMF control panel, then try it again and see what errors are listed in your forum errors log.

Do you have a test ID I can use on your site to take a look?  One that you assigned to a member group with the Add privilege in the custom page block of course. hehe

RoarinRow

Quote from: Thurnok on August 21, 2006, 06:44:53 PM
Did it create an entry in your database?
Clear your forum errors via the SMF control panel, then try it again and see what errors are listed in your forum errors log.

Do you have a test ID I can use on your site to take a look?  One that you assigned to a member group with the Add privilege in the custom page block of course. hehe

Yes it did create an entry in the database.

You can use as a test:

User ID - Codetest
Password - codetest

http://www.avalanchestyle-test.com/forum/index.php

SMF 2.0 RC3
TP 1.0 beta 5-1
Wordpress 3.0

Thurnok

#25
Ok... new code in first post.  This should fix "finally" the issue for those with their forums not in the root of their domain (http://www.mydomain.com/forum/index.php).

This one should work for everyone finally.  heh

Sorry for the delay... test it out and let me know.  :)

NOTE: Caveat in IE - you must click the button, not press enter, after entering the URL.  Might be OK on some IE versions however.

RoarinRow

Ahhh, that worked!   :up: 8)

SMF 2.0 RC3
TP 1.0 beta 5-1
Wordpress 3.0

londonhogfan

great work.  I like it.  Do you know of a way that they can publicly show their page?  would maybe be a small mod for tp... url of something like .com/index.php?mypage=[usernumber]

that way they could add a myspace page, or whatever they wanted within your site.

actually there is probably a way to integrate this into the "Profile Summary" page. hum...

Thurnok

Sorry for the late reply, I'm on vacation and have my nephew and neice in town.

Well, to add it to their profile summary is one way.  Though that would make it a mod instead of a simple block snippet.  I'm not opposed to doing that, but I like the idea of putting anything possible in a snippet for a number of reasons.  The most important one being that it is easier for the site owner to integrate since they do not have to perform a mod manually, or install a package which may or may not have implications to their site when they upgrade SMF and/or TP in the future.

However, just thinking about the code to perform what you are looking for, I can say that it would be a simple matter for me to add it to the existing snippet.  I probably will have time tonight to do that, so look for it here later.

Thurnok

Custom Page 1.0
A TinyPortal phpblock snippet
This is a new version of the Custom Page block code.

New Features:
  • Webmaster can allow/disallow public enabling of user's custom pages

    When enabled:
  • User can elect to have their custom page public or not
  • User can select any "public" custom page of other users for display
  • Retains user public selection
  • Retains user's selected page (whether their own or someone elses)
  • Displays your own custom page's URL in the urlbox even if you have another page selected
  • If you have another user's custom page selected and they remove it from public access, you will revert back to displaying your own custom page (if you have one or the defaults otherwise)
Automatically updates previous Custom Page table as necessary.  Creates table for new installs.

New Variables in configuration:
$cp_allow_public - set to true to enable public user custom pages.

Get the code from the original post in this thread along with original information.

This website is proudly hosted on Crocweb Cloud Website Hosting.