| Joomla - How to add a custom field |
| Vendor | Open Source Matters |
| Platform | Joomla (Linux) |
| Version | 1.5.x |
| WebDev - Joomla |
| Thursday, 22 December 2011 17:46 |
|
Within this tutotial I will show you the nessecary steps required to add a custom field named 'Version' to your Joomla site. This field will be displayed within both the administrator console and the published article. 1. Configure DatabaseWithin phpmyadmin run the following SQL command ALTER TABLE `jos_content` ADD `vers` VARCHAR( 255 ) NOT NULL 2. Edit PHPNext we will edit the core Joomla files (php) so that the field is displayed in both the admin console and the article itself. 2.1 Change Directorycd /var/www/html/[webroot]/ 2.2 libraries/joomla/database/table/content.phpAt line 88 add the following line, var $vers = null; 2.3 administrator/components/com_content/controller.phpAt line 327 add the following line, $row->vers =$item->version; 2.4 administrator/components/com_content/admin.content.html.phpAt line 835 add the following. This will add the new field to the administration console when creating a new article. <table class="adminform"> 2.5 components/com_content/views/article/tmpl/default.phpAt line 61 add the following. This will display the new field within the article. <?php 3. Edit CSSIn order to keep your new field aligned within the article manager the following CSS entry is added to your templates CSS. .customfieldtd { 4. ExampleBelow shows you the changes should look once you have made the changes above.
|
Latest Articles
- F5 LTM VE 10.2.x - Interfaces not recognised
- Cisco ASA - Security Levels / NAT Control
- F5 LTM - OneConnect
- Django - CSRF verification failed. Request aborted.
- F5 LTM VE - Unable to attach to PCI device 02:01.00 for Interface 1.1
- F5 LTM - Connection Management
- Brocade ADX - FTP
- PKI - Chain of Trust
- Juniper SRX - Site to Site VPN using a Dynamic IP address
- F5 LTM - How do I perform software installations ?
- Juniper SRX - NAT
- Juniper SRX - How to configure a route based VPN
- Juniper SRX - Dynamic VPN
- Juniper SRX - How to configure a policy based VPN
- Brocade ADX - NAT
- Brocade ADX - CSW nested rules
- How do I upgrade a Juniper SRX Series gateway
- Cisco ASA - How do I capture ARP`s ?
- Juniper SRX - Configuring Source NAT with pool
- Running a packet capture on a Juniper SRX
Popular
- Proxy ARP – SPLAT
- Check Point Commands
- IPSO - Commands
- ASA 8.3 - How to configure NAT
- vSphere - Creating User and Group Permissions
- PEMU - Free Cisco PIX Firewall Emulator / Simulator
- Configuring Wireless Connectivity within Backtrack 4 r2
- Juniper Netscreen Commands
- Juniper Netscreen - NAT Explained
- How do I install snmpwalk / snmpget using Yum ?
- Netscreen - NSRP
- ESX Convertor - The session is not authenticated
- Troubleshooting a Netscreen Site 2 Site VPN
- ESX - ViClient Cannot connect to host
- Endpoint Connect Installation / Troubleshooting Guide
- Check Point - How to Reset SIC
- ESXi - Connecting to a named pipe
- Netscreen - Routing Basics / Virtual Routers / PBR
- Check Point Logging Troubleshooting Guide
- Configuring Windows 2008 R2 as an NTP Server


