Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    PHP




Deletion And Editing Of Modules


i'm creating a miniature CMS. At the moment i'm working on the creation/deletion and editing of modules. I've got the creation working. But i'm struggling on the deletion and editing.

This is what i was thinking:

[Deletion]

1. (ID) Module 1 [Delete] (Link: modules.php?do=delete?name=Module%201&id=1)

[Editing]

1. (ID) Module 1 [Edit] (Link: modules.php?do=edit?name=Module%201&id=1)

How would i make it so the URL was that?




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
IE6 & Cookie Deletion
I have always previously always used cookies for authentication and on both sides (Netscape & IE) it has always operated flawlessly. Now that I have finally decided to try out IE6 i'm finding some problems with deleting cookies. Are there any bugs out there that I should know of?

Selecting Db Results For Deletion.
I am having a problem trying to select a number of unique db results from a db driven printed table (using a loop to print). I want the results selected (via a checkbox button) to be identified using their unique ID number, then passed to a php deletion script and deleted from the DB (the ID nums are passed)

In other words I am trying to delete threads from a forum DB.

Timed Deletion In Database
Does anybody have any pointers for code that will delete a record by setting an expiration date for it. I want to have news stories delete say 2 weeks after they have been posted automatically, I am using php and mysql?

Mass Deletion/Paging
I am a first timer here and I hope to enjoy the forum in the long run. I have a question regarding mass deletion and pagination or paging.

I have the following code/method which displays the search result and I want, within the search result, to allow staff or members with appropriate access to be able to delete (multiple records via checklist) records from the database. The methods are under index.php and here is the code below: Code:

How Do I Return Result Of Mysql Row Deletion
The data entered by a user on form 1 on page1.php is posted to
delete.php to remove that row from a table. After the SQL operation
the user is returned to page1.php.

How can I determine the success or failure of the SQL operation so I
can display an appropriate response message to the user?

How To Ensure Deletion Of Session Files
I am looking for the setting in php.ini what can be configured to make sessions expire and session files removed. Can it be the following entry or is it something else?

; After this number of seconds, stored data will be seen as 'garbage' and
; cleaned up by the garbage collection process.
session.gc_maxlifetime = 1440

Php-gtk + Modules
I'm trying to move some server code to a php-gtk app (under windows). I've got it (binary download) working with the samples.
The code i'm trying to use uses functions from php_zlib.dll as well as others, so i'm trying to include them. However the binary version of php-gtk doesnt come with the modules, and if i use the modules from my version of php (4.0.6) it comes up with errors, and if i try and use php-gtk with my version of php it comes up with errors and crashes, though it says it should work from 4.0.5.

PHP Modules
I'm not sure whether this can be done or not, but I guess there's no harm in asking.

The site I've built utilizes the 'domxml' PHP module. Unfortunately, few hosting providers seem to utilize this module. Is there any way to utilize this module dynamically, despite that the server hosting the PHP script doesn't have it loaded?

PHP Script Modules
I have written a PHP application that numerous companies are paying to use. There are a few companies that request features to be added to the application that don't always benefit the other companies using it. In these situations I have typically used a few if and else statements to use the new functionality for that company but leave the default funcionality intact for everyone else. There are lots of these little "features" in the system and the code is becoming spaghetti code. I need a way to organize these features.

Are there better ways of doing this? What I would like to ultimately acheive is a way to add the new functionality as a module or something that can be turned on and off for each company depending on their preference. I have been brainstorming on this topic for a while now and I can't seem to come up with any simple solutions. Any ideas you have are greatly appreciated!

Compiling The Modules
I'm having a lot of difficulty with compiling the modules for PHP, In fact I don't know where to start, you see Im pretty good at script type languages like PHP and Perl but when it comes to 'C' I have zero experience. I would really like to learn how to do this but would also find it useful to have the precompiled DLLs (windows NT).

Help On Pear Modules
First of all, I'm not a very seasoned programmer. It's just a hobby grown
out of control.

For a project I am working on I need to be able to send and receive e-mail.
I wrote some code for this myself, but that is just not quite good enough.
So I did a little research and found the Pear modules. I installed all the
Pear modules that I am supposed to need, but I don't understand the
documentation.

Could someone please explain to me how I am supposed to compose, send,
receive and identify the various parts of an incoming e-mail? I am, of
course, in full control of the mailsever.

Running PHP 4 & PHP 5 Together As Modules
We would like to upgrade our servers to PHP 5 and PHP 4
together as modules on the same server (not as cgi, not passing
requests to another server). I did some extensive searching on
this and we ran some tests over a year ago and did not find a
solution (other than proxy forwarding to a PHP 5 configured server).

When PHP went to version 4 from version 3, it was possible
to run both at the same time, and have users select by file
extension, i.e. .php4,.php5. It seems a naming conflict within
the code itself prevents that from working with PHP 5. Has anyone
discovered a way to do this?

We are running apache 1.3.x on RHEL 4.

PHP Graphing Modules
The problem is that i currenttly need to draw a horizontal bar graph that has to look pretty. I am looking around for perl graphing modules that can do this but i havent found any yet. My question is.. does anyone know off the top of their head if PHP can do this or has modules to do it? Because i might consider switching if it can.

Also are there any specific advantages of PHP over perl? i actually dislike perl a bit because of its stupid syntax and naming conventions and i would like to possibly switch if i can find a good enough reason.

Custom PHP Modules
I have been trying to find information on how to create my own php modules. So far i've been through various search engines, dev boards and sites. Nobody seems to have anything on the subject. I couldn't even find a single book on the subject.

Adding Modules Into PHP
Is there any way to add modules into PHP without recompiling it?? I need to add the GB module (I think thats what its called), the one that can create GIF images. If I can't will I have to recompile it and apache and MySQL or just PHP?

How Can I Compile Dynamic PHP Modules?
Maybe I've just missed something in the documentation, but since I can't seem to find it, I thought I'd post my question here.

I have RedHat 7.3 and the PHP 4.1.2 RPM package it came with. I used to compile my own versions of Apache/PHP/OpenSSH/SSL/etc, but since it's much easier to keep my machine up to date using RPMs and the "up2date" management tool, I now tend to shy away from compiling my own applications unless I can't find what I need from RedHat.

I'm now trying to add some extra functionality to PHP that RedHat didn't include with their PHP RPM. RedHat's PHP does come with a number of dynamic PHP modules, however(mysql.so, imap.so, ldap.so, etc.) I'd like to figure out how to create new ones (e.g. mcrypt). With Apache, I know I can build add webserver modules using the "apxs" tool. Is there a similar tool for PHP that will let me build new modules without having to run through an entire compilation process?

Getting PEAR Modules To Work
I'm new to Linux, setting up and running webservers. I
purchased an unmanaged server that came with a lamp configuration and
Plesk installed. I am trying to get PEAR functioning. I put a
php_info() page up and in the "Configure Command" section there is a
long list of things and "--without-pear" is listed. I know this should
probably say "--with-pear". How do I change this?

When I do a "pear list" command I get the following error:

Failed loading /usr/lib/php4/php_ioncube_loader_lin_4.3.so: /usr/lib/
php4/php_ioncube_loader_lin_4.3.so: undefined symbol:
zend_hash_add_or_update

This is after I upgraded from PHP4 to PHP5.

PEAR Modules HTML_QuickForm
I am using HTML_QuickForm and would like to output individual form
elements within an html/php document instead of $form->display() which spits
them out right there. I have site templates that I would like to place the
output into.

Addon-system (modules)
I'm making a news-system, and I want to enable the users of it to create their own modules for it (or download what others have made).. It should be fully extendable.. The problem is that I don't know how I should do it..

PHP, Apache (Linux), And Modules
I plan on installing PHP and Apache on a Linux box. (Plan on doing it with
binaries that come with Linux distro.)

One thing I'm confused about is how PHP is run as a module. I'm not that
familiar with this stuff, and I would have thought that there's something
called mod_php that needs installing. But I can't find much reference to
anything like that anywhere.

(Want to install as little stuff as possible.)

Execution Times/Modules
I am encoutering the following performance problem with php 3.0.16, the latest apache, running with compiled in php_mod on a sun ultra1.

i have written a set of php class files, which i use througout the site. the execution time of my skripts is very fast, but it seems that the class files i require (about 30k) slow down the performance enourmously. when i benchmark the site using ab with a php file which simply does html output and nothing else. its really fast, if i require my class files and do nothing else than the html output, the performance drops incredibly (no db connection, no computation, nothing)

i always thought that php_mod also keeps a byte code for the required pages in memory (like for example perl_mod). but now i doubt that. it seems that every request, forces php_mod to reload and recompile (or totally interpret ?!?!??) every file needed. is there anyway to increase performance when using multiple phpclass files? I know of conditional includes, but thats IMHO not a pretty solution.

Common Login For Diff Modules
I need to make a community site containing blog, forum, shoutbox, gallery, news, event calenders. Any one can give me suggestions like how can i make them accessible with one common login? Is it already handled by joomla or any other cms?

Running PHP 4 And PHP 5 Together As Modules, Linux, Apache 1.3.x
We have been running PHP 4.x on Apache 1.3.x with
no problems. After the first upgrade from php3 -> php4 were
were able to load both modules for php 3 and php 4 with no
problem. With an AddType directive we forced php 3 execution
for just those files ending in php3.

Thought we could do the same with php 5. We have a
lot of folks on 4 who may not be ready to upgrade yet, so
we were planning on letting php 4 handle anything ending in
..php or .php4 -- and use php 5 for just php5 extensions.

Did the same thing as before in our Apache Config,
we are running on Redhat 9 -- but can't get both 4 and 5
running together. It seems we can run one or the other, but
not both -- when we start apache we get ONE server process
that just sits there, nothing in the log files?

After some web searching could not find much, one
guy said there was a conflict in memory management and
you can't run the two together?

Anyone got this to work and how? Had posted this to
the alt..php group and still looking for a solution?

Apache 2.0.50 Php 5.1.2 - Modules Loads But Scripts Don't Run
I've compiled php 5.1.2 on a Madrake 10.1 box as an apache module. I have the following in my apache conf file:

LoadModule php5_module /usr/lib/apache2/libphp5.so
AddType application/x-httpd-php .php

The module is definately loading...I get this in the error_log:

[Fri Feb 10 15:24:03 2006] [notice] Apache-AdvancedExtranetServer/2.0.50 (Mandrakelinux/7.6.101mdk) PHP/5.1.2 mod_ssl/2.0.50 OpenSSL/0.9.7d configured -- resuming normal operations

So obviously the module is loading. When I try a simple test.php via apache, it sends the browser the text of the script as mime type application/x-php (which appears to be the mime type from apache-mime.types). I've done this countless times on other distros. What am I missing there? I thought those were the only two pertinent lines in the conf file.

PEAR Modules On A Hosted Server?
Is there any way to utilize PEAR, Specifically PEAR DB on a host (shared server) where I cannot install PEAR. I spent some time reading the Install documentation and my brain is numb, without drawing any conclusions. My host has a /php directory at the root, which appears to be a member of the include path. I have an object that requires PEAR DB and I do not think I can rewrite the DB calls in a reasonable amount of time.

Looking For A Couple Of Php Modules/libraries To Do Standard Web Stuff For Me
I've been contemplating two things for a php project I'm working on :

1) doing user security stuff (users, admins, super-admins etc), pref.
compatible with win32

2) doing pagination of large results lists

I've been looking (not terribly hard) for standard, mature php
libraries to help me do this. However I'm not confident of my own
opinion/evaluation of the little I've stumbled across, and have turned
to gin and tonic as an alternative. However, I've recently realised
that the gin isn't going to actually help me find these libraries.

Can anyone give me some recommendations?

I'm not looking for full-blown complex stuff. I'd rather have simple,
mature, stable, secure and EASY!

Displaying A List Of All Modules (extensions) Installed
I just signed up for a web hosting service. They have PHP, but can't
tell me which modules (extensions) are installed.

Is there a function, or some other easy way, to show all modules
(extensions) that are installed? phpinfo() doesn't do this.

INI File Editing...
Does anybody know how to open up an ini file and edit one section?

like find the section called [votes] and just replace the values underneath it, in that section alone?

vote.ini
[votes]
a=7
b=2
c=55
d=0

find that section, replace the values with there new numbers, without having to deal with what sections come before and after this, in the ini file?

Editing A String To Add A Before A '
Is there a function that allows you to add a before a ' in a string.
This is needed to store text in a mysql db and i was wondering if there
is function which can do this to any ' which DO NOT already have one
before them, this is so i can keep editing my text without all these
building up.

Editing HTML/
I'm looking for a way to editing my site on the fly (unfortunately I don't have DB support). I've been messing around with file functions, and that part seems to work fine.

My problem is that backslashes are being added when I post the form I use to edit the files, and if I understand it correctly, I can't just use stripslashes() since there are some backslashes I need to get through (like)Any solution to this?

Editing Rights
Is there any way to allow a PHP script editing rights to every file on its filesystem?

Php.ini File Editing
I need your knowledge,

I want to add to my website php.ini file to change the settings of my
mail() function so that my function is working fine except that the
sender email is not my user but nobody@hostingprovider.com so Someone
told me that its easily edited using php.ini but he dont know how, so
I thought that you could help me in this situation.

more details about my hosting:
- Linux host
- php 4.4.6
- apache

Editing .htaccess
Is there a way to edit a file (in this case .htaccess) in PHP to add a line of code?
EX. What I want to do is add this line to .htaccess: DirectoryIndex main.php?id=5

Editing A Table
is it possible to print a table and then that the user can edit it? My site is for an institute so in a colum will appear all the names of the students and I want that they can give all the notes next to their names, so I was thinking in do it with a table but i dont know if it is possible to edit the table: Code:

Help On Editing PHPBB
I do manage a website and it includes a PHPBB forum, obviously placed at /forum (¿why to use a weirder path? :P). The thing is that my site is more than a forum, it has more content. I have menus almost everywhere, it's very navigable; but if you go into the forum, you can only get back to the other sections of the site using the back buton or removing everything starting from /forum in the address bar. Of course, this doesn't fit my site's philisophy, which is almost to put menus even inside the menus in every page, so you can go from everywhere to everywhere... I hope you cacth it. I've noticed that it shows the domain and title I put in the admin panel. Well, what I'd like to do is to make this text link to my homepage, placed at /index.php or simply /. The problem is that I'm completely lost when trying to do something in PHPBB's source files. I don't know which file should I edit, nor where should I add the code. These files are a code labirynth for me, and I need to edit them to fit my site's needs.

Looking For A PHP App For Editing Pages
Any ideas?  Basically something that would allow me to upload/copy/delete/edit webfiles.  It would probably use a WYSIWYG javascript editor.  Not really looking for a CMS because they don't work with existing html files.

Form Editing
I am trying to call information from a MySQL database in for form of an editable form.  I want the info to be called into a box that can by typed in and so far that works. 

What I want to do next is to be able to change what is in those boxes and click an update button which updates what was called from the database to what I typed in the box.  The code I wrote is below and almost works. I'm not sure what the problem is. Code:

Editing An Xml File
I have an xml file that I use to store information in. I want to be able to add info to it without deleting whats in the file.

Drop Down Box Editing
I have 3 linked drop down boxes ( Eg: Country, State and City ) .  I've  set values for the drop down boxes initially and  I would like to edit the values later. Is it possible to show/highlighte the set values ( the value I've put earlier ) while editing the drop down boxes using  PHP or AJAX.

Editing A Table
i've checked my code like a thousand times and it seems to me there're no syntax errors in it, but I still don't manage to get the damn thing working. It's a script to update an event stored in a db, you can edit both the description as the date of the event. Code:

Editing A Row In A Table
I'm having trouble editing a row. The existing data echoed into the form ok but if I try to change anything and click submit, the error message at the end of the script is echoed. Code:

Editing Data
What i want to do is edit details that have been taken from mysql database and display them in a text box.

I'm under standing what I’ve done so far which was to bring the job id code of the job that i want to edit from another page and i no the code to edit but what i can’t do is display the job data into a text box so it can be seen and edits can be made. All the books and website and forms I’ve read don’t show how to display the data to a text box or it’s so complicated that i don’t have a clue what’s going on? Code:

Editing System Passwords With Php
I need to create a php script that adds new users to my FreeBSD server. I've tried running the 'pw adduser' command through a script, but I can't pass a desired password to it.

I've also tried using the pw command with a password encoded in md5, but I'm still pretty confused about how the encryption works.

Editing The Win32 Registry
Does anyone know if the equivalent of PERL's Win32::Registry module exists for PHP anywhere? If so, I'd be grateful for a push in the right direction.

Editing An Element Within An Array
I have a two-dimensional array that looks like this:
array(
array(0, 123),
array(0, 234),
array(0, 345),
array(0, 456)
)
I want to REMOVE any element that contains 234, and I want to
INCREMENT the first value for any element that contains 345, to make
it look like this:
array(
array(0, 123),...

Editing Info In A File
I am using a tab delimited file to provide information for a page to be displayed. I have used fgetcsv() to get information from the file, and it returns an array of information. I was wondering if there is a way I could change information in the file. For example lets say that $content[2] = "This" how could I change it so that, $content[2] = "That". I know how to change the variable to a different value, but I haven't figured out how to change the actual file.

Editing One Line Of A File.
MySQL ahs been giving me tremendous problems ever since I tried to switch to version 5.0.20. I thought that I might make my own SQL program, out of PHP code.

But if a user of it has a table with hundreds or more entrys, editing one line would take hours. If you can't get PHP to edit one line with a few functions, what about splitting a file into three parts and then merging them together after editing the middle part, like so: Code:

Editing Files In A <textarea>
I've written this program to let me edit ASCII files on my server in a <textarea>. However, if the file that is being edited contains a textarea within it, then I get problems.

what I want to do is read this file into the textarea but I want to convert all of the < and > characters to &lt; and &gt; 's. I figgered you'd do this through Regular Expressions: however these are poorly documented in the PHP book I have, though the Perl book I have tells me how to do this. Could someone tell me how to do this, IN PHP! Code:

Editing Mysql Db Using A Php Form
I am working on a Sig Request database. People submit their request using a form and it's posted into a databse and then displayed beneath the request form. This is working fine. I am having trouble however with my edit.php file.

I want to be able to load a users information, which I have done using this code below. It displays in a form. I change 1 or 2 of the fields, such as the completed field and designer field and click update but it doesn't actually update the database.

The page first lists all the requests. It lists their ID, Name and then it says "Edit this Request" which opens a page with their sig request details in. Here is my code below for the edit.php file. Code:


Copyright © 2005-08 www.BigResource.com, All rights reserved