Home
Download
Add-ons
Help
Forum
Organisation
Project
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
May 16, 2012, 10:14:50 PM
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Search:
Advanced search
Wollen Sie dem WebsiteBaker Team beitreten?
Nähere Informationen finden Sie unter
hier
und auf unserer
neuen Webseite
.
155094
Posts in
21661
Topics by
7721
Members
Latest Member:
arrow345
WebsiteBaker Community Forum
English
Droplets (PHP code for use with Droplet module) & Snippets (raw PHP code)
(Moderator:
Argos
)
Edit this page as code snippet module
Pages: [
1
]
2
Go Down
Author
Topic: Edit this page as code snippet module (Read 8054 times)
RolfP
Offline
Posts: 18
Edit this page as code snippet module
«
on:
December 23, 2007, 12:06:27 PM »
Hi,
I modified the code posted at
http://forum.websitebaker.org/index.php/topic,2352.0.html
and created a module.
This module adds an image in template where ever you put the code
<?php frontend_edit(); ?> if the logged in account is allowed to edit the page.
On clicking image the backend editor opens the selected page.
See the attached modul.
Have fun.
Rolf
Logged
ruebenwurzel
WebsiteBaker Org e.V.
Offline
Posts: 7970
Re: Edit this page as code snippet module
«
Reply #1 on:
December 23, 2007, 12:30:00 PM »
Hello,
well done, easy to install, very easy to handle. Great snippet.
Thanks for your contribution to WB.
Matthias
Logged
berta
Offline
Posts: 11
Re: Edit this page as code snippet module
«
Reply #2 on:
January 04, 2008, 08:30:39 AM »
Rolf,
Thank you for your module, it works great, and makes it so much easier to ask other people to edit the pages. THANKS
Berta
Logged
Berta
diodak
Offline
Posts: 85
Re: Edit this page as code snippet module
«
Reply #3 on:
January 22, 2008, 12:33:15 PM »
You didnt notice that front login must be enabled. Good module.
Logged
Buchsbaum
JonH
Offline
Posts: 25
Re: Edit this page as code snippet module
«
Reply #4 on:
January 25, 2008, 01:44:07 PM »
Where's the attachment?
Logged
ruebenwurzel
WebsiteBaker Org e.V.
Offline
Posts: 7970
Re: Edit this page as code snippet module
«
Reply #5 on:
January 25, 2008, 01:50:24 PM »
in the first post
Logged
JonH
Offline
Posts: 25
Re: Edit this page as code snippet module
«
Reply #6 on:
January 25, 2008, 03:16:48 PM »
I swear it wasn't there before!
Logged
fsuk
Offline
Posts: 127
Re: Edit this page as code snippet module
«
Reply #7 on:
July 18, 2008, 03:32:48 PM »
Needs to be updated for 2.7, only works with the default group_id and not the group_ids field. i might give it ago if i have time, that is of couse unless theres a feature like this already built into 2.7??
Logged
You say deviant like its a bad thing...
fsuk
Offline
Posts: 127
Re: Edit this page as code snippet module
«
Reply #8 on:
August 07, 2008, 02:39:24 PM »
I have updated the module for WB 2.7 for multiple groups.
Theres probably some redundant code in there.
The updated module is attatched.
«
Last Edit: August 07, 2008, 03:17:14 PM by fsuk
»
Logged
You say deviant like its a bad thing...
aldus
Offline
Posts: 1238
Re: Edit this page as code snippet module
«
Reply #9 on:
August 07, 2008, 03:04:10 PM »
Sorry for the german:
so:
I cleaned it a little bit up ... e.g. no nessesay new database() needed,
and collecting the data before echo.
where are two variables left
- $old_admin_users und
- $admin_users.
both of them are only used one time - and never more; so they can be left/removed.
Regards
Aldus
«
Last Edit: August 07, 2008, 03:08:01 PM by aldus
»
Logged
fsuk
Offline
Posts: 127
Re: Edit this page as code snippet module
«
Reply #10 on:
August 07, 2008, 03:10:42 PM »
Thanks ill add it to the zip in my previous post
Logged
You say deviant like its a bad thing...
aldus
Offline
Posts: 1238
Re: Edit this page as code snippet module
«
Reply #11 on:
August 07, 2008, 03:23:15 PM »
But please test it before
I've made mass. changes ...
Regards
Aldus
Logged
fsuk
Offline
Posts: 127
Re: Edit this page as code snippet module
«
Reply #12 on:
August 07, 2008, 03:26:08 PM »
Yup it works fine, although i had to remore /n from the end of the Edit Page line as it wasnt starting a new line just printing '/n'
Logged
You say deviant like its a bad thing...
TN
Offline
Posts: 20
Re: Edit this page as code snippet module
«
Reply #13 on:
September 07, 2008, 01:50:17 PM »
Quote from: JonH on January 25, 2008, 03:16:48 PM
I swear it wasn't there before!
You can see the attachment only if you are logged in, if you have cookies allowed und if you have javascript allowed.
I think: not everybody should gets the code
Logged
Stefek
WebsiteBaker Org e.V.
Offline
Posts: 4868
Re: Edit this page as code snippet module
«
Reply #14 on:
September 18, 2008, 08:19:55 PM »
Hello!
This is a great upgrade!
I only have one question:
How can I modify the
<?php frontend_edit
();
?>
so I get a message when this snippet is not installed.
Thanks in advance.
Stefek
«
Last Edit: September 18, 2008, 09:43:48 PM by Stefek
»
Logged
"In a time of universal deceit, telling the truth becomes a revolutionary act."
- George Orwell, Nineteen eighty-four (1984)
doc
Guest
Re: Edit this page as code snippet module
«
Reply #15 on:
September 18, 2008, 09:07:05 PM »
Hi,
like done for the register_frontend_m
odfiles function called in the index.php of the most templates out there, so:
Code:
<?php
if (
function_exists
(
'frontend_edit'
)) {
frontend_edit
();
} else {
echo
'Sorry, to use this function, you need to install the code snippet xxx first.'
;
}
?>
Regards Christian
«
Last Edit: September 18, 2008, 10:17:51 PM by doc
»
Logged
Stefek
WebsiteBaker Org e.V.
Offline
Posts: 4868
Re: Edit this page as code snippet module
«
Reply #16 on:
September 18, 2008, 09:44:22 PM »
Thanks Christian!
Regards,
Stefek
Logged
"In a time of universal deceit, telling the truth becomes a revolutionary act."
- George Orwell, Nineteen eighty-four (1984)
mr-fan
Offline
Posts: 1555
Re: Edit this page as code snippet module
«
Reply #17 on:
September 22, 2008, 06:35:09 PM »
i have a question about the frontedit...
is it possible to make it easyer for a simple editor, after he made changes to his site, that he can with one click back to frontend.... or is this to complex in the backend....
or is there a other option that makes a sucess from a user to only one site to edit...save and look changes....in the frontend?
mfg mr-fan
Logged
erpe
Offline
Posts: 2077
Re: Edit this page as code snippet module
«
Reply #18 on:
September 23, 2008, 07:27:04 AM »
A click to the button and he turns to the frontend in new tab (see image)
rgds
erpe
Logged
stories about
be part of the Tutorials-Project
visit the jQuery-Showroom
mr-fan
Offline
Posts: 1555
Re: Edit this page as code snippet module
«
Reply #19 on:
September 23, 2008, 11:20:01 AM »
ups.... sry i only used the big red one
my brain is jumping to fast to think.....
greets
Logged
jrast
Offline
Posts: 315
Re: Edit this page as code snippet module
«
Reply #20 on:
February 23, 2009, 10:59:39 AM »
If i want to add a new group, i get this error:
Code:
Parse error: syntax error, unexpected T_VARIABLE in /home/opentopo/public_html/wb/modules/frontedit2.7/info.php on line 1
So, why do i get a error from a snippet if i want to add a new group in the WB backend? for me a strange thing...
@edit:
ok, Problem found.
the info.php file was in a wrong format and there was no white space betwen the <?php tag and the first variable.
«
Last Edit: February 23, 2009, 11:21:31 AM by jrast
»
Logged
- If life turns bad, just hang on! -
solbu
Offline
Posts: 22
Re: Edit this page as code snippet module
«
Reply #21 on:
March 12, 2009, 08:13:28 PM »
Quote from: RolfP on December 23, 2007, 12:06:27 PM
This module adds an image in template where ever you put the code
<?php frontend_edit(); ?> if the logged in account is allowed to edit the page.
I have a bug report.
If one use the Search function to search the portal as guest and is not logged in, the Edit link, with the image, shows up regardless of whether one is loged in or not. Clicking the Edit link results in one having to login thou, but still, it should not be displayed.
This only happens on the search page. (websitebakerurl/search/index.php)
I have tried to locate why it show up there as guest, but I am unable to figure it out.
Logged
My posts are licensed under a Creative Commons license
mr-fan
Offline
Posts: 1555
Re: Edit this page as code snippet module
«
Reply #22 on:
March 12, 2009, 09:29:47 PM »
Quote
I have a bug report.
If one use the Search function to search the portal as guest and is not logged in, the Edit link, with the image, shows up regardless of whether one is loged in or not. Clicking the Edit link results in one having to login thou, but still, it should not be displayed.
This only happens on the search page. (websitebakerurl/search/index.php)
i just have a short try - i don't can confirm this on my site! we have a site with the maincontent is for unregistered/unlogged in users and a short part is for spezial users with login!
i've the frontedit placed in the site - with your report i've tryed out imediatly but no such manner in my case!
mean guest in your case - no login or no access to edit a site??
because if you logged in and have no access to edit site - the fronteditbutton will display anyway...
rgds martin
Logged
solbu
Offline
Posts: 22
Re: Edit this page as code snippet module
«
Reply #23 on:
March 12, 2009, 09:46:53 PM »
Quote from: mr-fan on March 12, 2009, 09:29:47 PM
mean guest in your case - no login or no access to edit a site??
Correct. The user is not logged in.
On every page on the site, guest users do not see the image. However if the guest user use the search function, the edit image appears also for guests.
This happens Only on the /search/index.php page, where the search results also apears.
Logged
My posts are licensed under a Creative Commons license
solbu
Offline
Posts: 22
Re: Edit this page as code snippet module
«
Reply #24 on:
March 13, 2009, 02:34:22 PM »
Quote from: solbu on March 12, 2009, 09:46:53 PM
On every page on the site, guest users do not see the image. However if the guest user use the search function, the edit image appears also for guests.
This happens Only on the /search/index.php page, where the search results also apears.
I have just noticed another problem, that might help in debugging. Logged in users Do Not get the Edit image on the search page. The site owner noticed it.
We are in the process of launching a new design, using WebsiteBaker for the first time, and are trying various things.
This is the last remaning bug we need to resolve before we can launch the new CMS.
«
Last Edit: March 13, 2009, 02:36:20 PM by solbu
»
Logged
My posts are licensed under a Creative Commons license
Pages: [
1
]
2
Go Up
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> General Announcements
=> Security Announcements
=> Documentation
=> WebsiteBaker Website Showcase
=> Guest Area & Off-Topic
-----------------------------
English
-----------------------------
=> WebsiteBaker 2.9
===> Announcements
===> Help/Support
=====> Modules / Extensions
===> Suggestions
===> Software bugs
=> Help & Support
=> Modules
=> Droplets (PHP code for use with Droplet module) & Snippets (raw PHP code)
=> jQuery
=> Templates, Menus & Design
=> WebsiteBaker Language Files
=> WebsiteBaker 2.x discussion
=> WebsiteBaker 3
=> Archive (posts up to 2007)
-----------------------------
Deutsch (German)
-----------------------------
=> Ankündigungen
=> WebsiteBaker 2.9
===> Ankündigungen
===> Hilfe/Support
=====> Module / Extensions
===> Vorschläge
===> Softwarefehler
===> Erfahrungs und Testberichte
=> Hilfe/Support
=> Module & Snippets
=> Templates & Design
=> Tutorials
=> jQuery
=> Diskussion über WB
=> Off-Topic
=> Archiv für Themen bis 2007
-----------------------------
Nederlands (Dutch)
-----------------------------
=> Aankondigingen
=> Hulp & Ondersteuning
=> Niet-Terzake (Off Topic)
-----------------------------
Francais (French)
-----------------------------
=> Help/Support
-----------------------------
Italiano (Italian)
-----------------------------
=> Help/Support
-----------------------------
Bakery (WB shop module)
-----------------------------
=> Bakery English
=> Bakery Deutsch
-----------------------------
KeepInTouch (Multi Contact Module)
-----------------------------
=> KeepInTouch English
=> KeepInTouch Deutsch
Loading...