zc5 Posted June 28, 2013 Share Posted June 28, 2013 I am a novice php coder and I have been trying to figure out how to personalize dumpHTML (a tool in php i use to convert MediaWiki content into html). When i use this tool it places a footer tag at the bottom of every page. I want to replace some of that content with my own personalized one. The problem I am having is i know what html content i want but i do not know how to implement it using php. This is the original default code: <div id="footer"> <?php if($this->data['poweredbyico']) { ?><div id="f-poweredbyico"><?php $this->html('poweredbyico') ?></div><?php } ?> <?php if($this->data['copyrightico']) { ?><div id="f-copyrightico"><?php $this->html('copyrightico') ?></div><?php } ?> <ul id="f-list"> <?php if($this->data['lastmod' ]) { ?><li id="f-lastmod"><?php $this->html('lastmod') ?></li><?php } ?> <?php if($this->data['numberofwatchingusers' ]) { ?><li id="f-numberofwatchingusers"><?php $this->html('numberofwatchingusers') ?></li><?php } ?> <?php if($this->data['credits' ]) { ?><li id="f-credits"><?php $this->html('credits') ?></li><?php } ?> <?php if($this->data['copyright' ]) { ?><li id="f-copyright"><?php $this->html('copyright') ?></li><?php } ?> <?php if($this->data['about' ]) { ?><li id="f-about"><?php $this->html('about') ?></li><?php } ?> <?php if($this->data['disclaimer']) { ?><li id="f-disclaimer"><?php $this->html('disclaimer') ?></li><?php } ?> <?php if($this->data['tagline']) { ?><li id="f-tagline"><?php echo $this->data['tagline'] ?></li><?php } ?> </ul> </div> I would like to replace this content so that instead it spits out this html code when it translate: <div class="memitem" id="footer" align=right> <em>© 1993-2014 Company XX.</em> | Visit Us: <a href="http://www.website.com">www.website.com</a> | Send Feedback: <a href="mailto:docfeedback_@website.com">docfeedback_@website.com</a> | See: <a href="../../../../Terms_of_Use.html">Terms of Use</a> <a href="../../../../Privacy_policy.html">Privacy Policy</a> </DIV> What i have been doing is completely removing the original code and the manually pasting that html code into my pages which sometimes takes a while. I want this process to be automatic. Thank you so much for the help guys! Quote Link to comment https://forums.phpfreaks.com/topic/279670-replacing-default-content-with-personalized-need-help-on-php-to-html-translation/ Share on other sites More sharing options...
ginerjm Posted June 29, 2013 Share Posted June 29, 2013 Not very clear on how the default code is being generated. Obviously you want to tell whatever "other" code is generating that to generate your new code. So - can you show the "other" culprit? Quote Link to comment https://forums.phpfreaks.com/topic/279670-replacing-default-content-with-personalized-need-help-on-php-to-html-translation/#findComment-1438471 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.