Userpanel CP

Post custom hacks and enhancements for phpwcms here only. Maybe some of these things will be included in official release later.
kaiser-web
Posts: 32
Joined: Tue 29. Jun 2004, 21:34
Location: Hamburg [DE]
Contact:

Post by kaiser-web »

Hey, first I want to thank you for the hack.
I installed a blank new phpwcms pre1.2.9 and wanted to install your hack and guess what: the index.php changed:

Code: Select all

$content['page_end'] = '';
if(VISIBLE_MODE == 1 || VISIBLE_MODE == 2) {
	$content['page_end']  = '<div id="VisualModeIndicator">';
	$content['page_end'] .= VISIBLE_MODE == 1 ? 'user: ' : 'admin: ';
	$content['page_end'] .= html_specialchars($_SESSION['wcs_user']);
	$content['page_end'] .= ' <a href="phpwcms.php?do=articles';
	if($aktion[1]) {
		$content['page_end'] .= '&p=2&s=1&id='.$aktion[1];
	}
	$content['page_end'] .= '" target="_blank" title="edit article">';
	$content['page_end'] .= '<img src="img/symbols/fe_page_edit.gif" width="16" height="16" alt="edit article" border="0" style="vertical-align:middle"'.HTML_TAG_CLOSE;
	$content['page_end'] .= "</a></div>";
}
How to add the following mentioned within your install tut now:

Code: Select all

// define VISIBLE_MODE 
// 0 = frontend (all) mode 
// 1 = article user mode 
// 2 = admin user mode 
if(empty($_SESSION["wcs_user_id"])) { 
define('VISIBLE_MODE', 0); 
} else if($_SESSION["wcs_user_fe"] == 0) { 
define('VISIBLE_MODE', 2); 
} else { 
define('VISIBLE_MODE', $_SESSION["wcs_user_admin"] != 1 ? 0 : 2); 
} 
?

thx, and also greeting from Hamburg,
kaiser-web[/code]
casi
Posts: 2
Joined: Wed 21. Feb 2007, 11:35

Post by casi »

hallo

stehe vor der gleichen hürde wie "kaiser-web[/code]". gibt es schon eine lösung wie den code für 1.2.9 anzupassen (visible_mode)?

danke
casi
User avatar
pico
Posts: 2595
Joined: Wed 28. Jul 2004, 18:04
Location: Frankfurt/M Germany
Contact:

Post by pico »

Hi

think this Part has moved to ../include/inc_lib/default.inc.php

Original:

Code: Select all

// define VISIBLE_MODE
// 0 = frontend (all) mode
// 1 = article user mode
// 2 = admin user mode
if(empty($_SESSION["wcs_user_id"])) {
	define('VISIBLE_MODE', 0);
} else {
	define('VISIBLE_MODE', $_SESSION["wcs_user_admin"] != 1 ? 1 : 2);
}
so you can change it to::

Code: Select all

// define VISIBLE_MODE
// 0 = frontend (all) mode
// 1 = article user mode
// 2 = admin user mode
if(empty($_SESSION["wcs_user_id"])) {
define('VISIBLE_MODE', 0);
} else if($_SESSION["wcs_user_fe"] == 0) {
define('VISIBLE_MODE', 2);
} else {
define('VISIBLE_MODE', $_SESSION["wcs_user_admin"] != 1 ? 0 : 2);
}
not tested :!:
Lieber Gott gib mir Geduld - ABER BEEIL DICH
Horst - find me at Musiker-Board
phalancs
Posts: 793
Joined: Thu 19. Feb 2004, 05:09
Location: Germany

Post by phalancs »

thanx pico, i am sure that it works with your hint - thanx for sharing the info!

We should now reintegrate "user selection" for structurelevels. This should not be so complicated. but I do not have time for it.

another hint: it is pretty easy to change the user selection part to make it work for groups. then you only also have to edit the visible mode part mentioned above to make it work. Ok groups then anyways have to be set via phpmyadmin.

This way group management can be easily set up pretty easy.
2008
skeut
Posts: 11
Joined: Fri 4. Nov 2005, 16:14

Post by skeut »

Hi everybody,

I installed the userpanel as mentioned in the file "install.txt" and I changed "VISIBLE_MODE" in the file "default.inc.php"

I'm using phpwcms 1.2.9.

In the backend: it seems very well. I can create a article "Userpanel".

But in the frontend, I see only the title of the article. No fields, labels, ....

Has anybody an idea about that ?

thank you.
jpwalker
Posts: 8
Joined: Thu 1. Mar 2007, 09:05

Post by jpwalker »

Hi,

I've got the same problem !

The installation came very good, the ct userpanel appear in the listbox...

Anyone have work on ?

Thx

[EDIT] : problem solved, just test without be login and don't fill all fields in the backend. And it don't work without template.
skeut
Posts: 11
Joined: Fri 4. Nov 2005, 16:14

Post by skeut »

hi jpwalker,

it doesn't work on my site.

I have created a ct userpanel and saved it.

After that I have tested without be logged. I have already installed a template too.

Nothing in the frontend, only article title. :!:

But what do you think with
don't fill all fields in the backend


skeut.
jpwalker
Posts: 8
Joined: Thu 1. Mar 2007, 09:05

Post by jpwalker »

skeut wrote:hi jpwalker,

it doesn't work on my site.

I have created a ct userpanel and saved it.

After that I have tested without be logged. I have already installed a template too.

Nothing in the frontend, only article title. :!:

But what do you think with
don't fill all fields in the backend


skeut.
Hi skeut,

So, I'm really sorry but after integrate some other CT my userpanel don't work again :( I don't know where it comes, I'm still searching for solutions :x

++
phalancs
Posts: 793
Joined: Thu 19. Feb 2004, 05:09
Location: Germany

info

Post by phalancs »

Hey guys, thanx for your information.

Some official words about this:
Remember that the userpanel has not been oifficially tested with any version higher than v1.2.6!! I wanted to wait for a real new official release. As there is v1.3 out now, which supports plugins, you finally see why I decided to do so.

Again: The userpanel basically works for older versions. For v1.3 there should be another concept. If anyone has the time to convert it you are free to do so. Until may I will not have the time to work on this. Afterwards I will definitely do (if necessary).

The userpanel was intended to fill the gap where there was no official progress in this respect. Although there is anyways no usermanagement progress right now, in other points phpwcms has changed a lot.
This is why you cannot easily install it on any new phpwcms. Although there might be a relatively simple workaround, I am sorry to tell you that I cannot find it out for you.

Anyways, thanx for all the support and be sure to come back regularly, as this story here is not yet over :)

P.S.: If anyone has news about how to get it to work with the new versions, tell us!
2008
User avatar
jsw_nz
Posts: 907
Joined: Fri 2. Apr 2004, 02:42
Location: New Zealand

Post by jsw_nz »

Hi Phalancs,

Now might be a good time (of coiurse - when when you are free) to have a good solution between what you and erich_k4 have been developing in this area. I for one would be most patient in this regards - but definely would like to see something workable in usermanagement area set up - building on OliG's newest. Am looking forward to seeing the likes of you and other great developer's in the community harness the plugin API.

All best
-john-
User avatar
skipper
Posts: 52
Joined: Thu 13. Mar 2008, 12:40
Location: Wardenburg
Contact:

Re: info

Post by skipper »

phalancs wrote:Remember that the userpanel has not been oifficially tested with any version higher than v1.2.6!! I wanted to wait for a real new official release. As there is v1.3 out now, which supports plugins, you finally see why I decided to do so.
Hi Phalancs!

are there new developments on the 1.3 version?

Thx!
Chr.
Die Informationen rund um den Wassersport in Holland:
Portal: http://www.segler-in-holland.de
Forum: http://www.segler-in-holland.de/forum
rushclub
Posts: 915
Joined: Tue 17. Feb 2004, 18:52

Re: Userpanel CP

Post by rushclub »

thanks again for this nice solution.
have used it on an old installation (1.2.6) without any problem ;)

rush
3 (!) Jahre warten reichen mir. Ich bin erst mal weg.
User avatar
Jensensen
Posts: 3000
Joined: Tue 17. Oct 2006, 21:11
Location: auf der mlauer

Re: Userpanel CP

Post by Jensensen »

today i noticed that some pro-coders already work with a new "userpanel", while we, me, the foolish code-cripples, still wait for an "official" solution/implementation.
{so_much} | Knick-Knack. | GitHub
Umlaute im URL sind meistens immer Kacke.
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: Userpanel CP

Post by update »

WHERE? WHO? WHEN? WHY? WHAT? :shock: :lol:
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
nebenaube
Posts: 139
Joined: Fri 23. Nov 2007, 20:39
Location: Redlands, CA
Contact:

Re: Userpanel CP

Post by nebenaube »

I have the fe_Login cnt part working this way... but without the message access that was described at the beginning of the thread. After a few modifications, I started posting the methods here hoping to collaborate with others in the community but people laughed at my attempts, so like phalancs did once before elsewhere on this board; I redacted the info.

http://www.eenac.com (currently r307) works this way and uses geolocaton to set the weather location and set the origin of the search radius in the classified ads section. I've just finished integrating these modifications with r327 over at http://www.sustainableeauclaire.org/index.php. Go try it and register, you will get an email that contains a account verification link that can used to activate the account and automatically login you as a feuser. Once the account is verified, the regular login screen also works.

Soon, I will add captcha to the registration form and then re-code the backend user management to reset the geolocation parameters when the zipcode is changed from the backend.

I don't need user permissions beyond fe, fe&be, be and admin. I see that the work on GURM is progressing, I just can't wait that long.
Post Reply