CodeCharge Studio
search Register Login  

Visual Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Problem publishing changes made to common.php

Print topic Send  topic

Author Message
Danny
Posted: 09/10/2004, 10:00 AM

I'm trying to add an include statemant at the bottom of the common.php file in order to have some of my "common routines" available in all files.
The problem is that although the common.php file in the source code gets changed and saved this is not reflected in the published version of common.php.

I tried deleting the published version and then re-publishing common.php with the same results – it's as if the published files' origin is a completely different file from the file common.php in the source code folder.

I'm running CodeCharge 2.3.2

Can anyone help?

Danny
padutoit

Posts: 9
Posted: 08/11/2005, 6:28 AM

I have this problem two, stupid thing is I have added custom functions to two other projects with out a problem but on the third project if I add any custom code to Common.php and publish the any of the php pages are returned blank remove the custom code republish and hey presto they all work...version 2.3.2.24

Someone help, Yessoftware are any of you there :-/
View profile  Send private message
feha


Posts: 712
Posted: 08/11/2005, 8:47 AM

You should add all your custom functions in separate php file

and include that file att the bottom of Common.php


_________________
Regards
feha

www.vision.to
feedpixel.com
View profile  Send private message
feha


Posts: 712
Posted: 08/11/2005, 8:49 AM

When you make changes in common file first save than click on commonfiles at the top of left side directory in css and click generate code.

close whole project
than reopen it and generate the project

_________________
Regards
feha

www.vision.to
feedpixel.com
View profile  Send private message
padutoit

Posts: 9
Posted: 08/11/2005, 8:54 AM

fair enough but can anyone explain why it has worked in the two projects before this one, shame vesion same setup php/mysql/apache just concerns me that it works willie nellie...
View profile  Send private message
peterr


Posts: 5971
Posted: 08/11/2005, 9:46 AM

I suspect that the custom code itself is causing this, or it was put in the wrong place (possibly after "?>").
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message
padutoit

Posts: 9
Posted: 08/11/2005, 10:25 AM

nope not in the wrong place that is for sure, prehaps the code but I can't see anything wrong with it, maybe a fresh set of eyes here is the code a short function to update the history table

function UpdateHist($input)
{
$db = new clsDBippatcon();
$SQL = "INSERT INTO phistory (phipadd,usrid,phdesc) VALUES (". $db->ToSQL(getenv("REMOTE_ADDR"),ccsText) . "," $db->ToSQL(CCGetUserID(),ccsInteger) . "," . $db->ToSQL($input, ccsMemo) . ")";
$db->query($SQL);
$db->close();
}
View profile  Send private message
peterr


Posts: 5971
Posted: 08/11/2005, 12:20 PM

This function is causing a problem/error for me. Possibly your PHP is just configured not to display errors (or some errors), so it shows blank page instead. The error seems to be due to the lack of concat period (.) in this part: "," $db
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message
padutoit

Posts: 9
Posted: 08/11/2005, 2:52 PM

there see a fresh set of eyes and turning errors on and all sorted, sorry to have wasted your time Peter old chap O:) ...but at least we know we can add custom code to Common.php with out "USER" error :-D
View profile  Send private message
peterr


Posts: 5971
Posted: 08/11/2005, 3:01 PM

Yeah, this is a classic case of "I've done everything right, have done it many times before, so why doesn't it work now?". But don't worry, it happens to all of us ;-)
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.