Joomla! Discussion Forums



It is currently Thu Nov 26, 2009 5:39 am (All times are UTC )

 




Post new topic Reply to topic  [ 4 posts ] 
Author Message
Posted: Sat Dec 01, 2007 3:46 pm 
Joomla! Enthusiast
Joomla! Enthusiast
Offline

Joined: Sun Jul 15, 2007 4:08 am
Posts: 125
I am creating a new component, and now how to do this.  This component, however, needs another component (i.e. com_registration provided in the core installation) to be modified slightly.  When installing my new component, I would like to replace a file in components.com_registration with a new file, and ideally put back the original file if my new component is uninstalled.  I could obviously manually upload the modified com_registration file via a FTP client, however, would rather use the Joomla Installers/Componenets/Install New Component backend.  Is it possible to do this, and can the XML installation file for my new component be modified to effect another component?

Thanks


Top
   
 
Posted: Thu Dec 13, 2007 12:51 am 
Joomla! Enthusiast
Joomla! Enthusiast
Offline

Joined: Sun Jul 15, 2007 4:08 am
Posts: 125
I am still trying to do this.  Any ideas?

Basically,when adding my new component, would like to replace a file in another component.

Thanks


Top
   
 
Posted: Sun Dec 16, 2007 5:18 pm 
User avatar
Joomla! Intern
Joomla! Intern
Offline

Joined: Wed Mar 07, 2007 1:23 pm
Posts: 71
you have to rename your modified registration.php file to components/com_registration/registration.php by yourself (rename(), copy(), whatever)
you can do this in a com_install() - function of your component (install.your_component.php)

_________________
self-appointed Joomla 1.0.x help desk :-)
leagueman.joomlabasic.com
What I would change in Joomla 1.0.x


Top
  E-mail  
 
Posted: Sun Dec 16, 2007 7:47 pm 
Joomla! Enthusiast
Joomla! Enthusiast
Offline

Joined: Sun Jul 15, 2007 4:08 am
Posts: 125
Thank you Leagueman.  That worked great!  I never used com_install() before now, but will do in the future.

One question related to com_install.  I have seen people have it echo html (i.e. description, licience agreement, installation feedback, etc).  I did the same, and while it did not cause any problems, I didn't see where it sent anything to the screen.  I added some code in com_install and com_uninstall to confirm all went well, and give feedback.  Is it possible to have com_install send text to the screen?

Thanks!


Top
   
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

Quick reply

 



Who is online

Users browsing this forum: bustersnm and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group