Linkedin.com field mod for SMF (part 3)
In previous article we improved our Linkedin.com mod for SMF. But I doubt each user will go to his/her profile page and submit hist linkedin.com profile page. Lets add new feature to our mod: users are able to enter their linkedin.com profile on the registration page (and it’s not required).
To add this feature I’ve created another xml files with version 1.1
Now we will amkechanges in Register.template.php file:
<file name=”$themedir/Register.template.php”>
<!– A seach operation, with search rules and code to modify the file with. –>
<operation>
<!– Search for this text before the code we add. You can also search for after, and the end of the file. –>
<search position=”before”><![CDATA[ <td>
<input type=”password” name=”passwrd2″ size=”30″ tabindex=”‘, $context[’tabindex’]++, ‘” />
</td>
</tr>’;]]></search>
<!– Add this text when we find it. Note that it’s on it’s own line on purpose, and the CDATA keeps things clean. –>
<add>
<![CDATA[
echo ‘</tr><tr>
<td width=”40%”>
<b>Linkedin.com:</b>
</td>
<td>
http://www.linkedin.com/<input type=”text” name=”default_options[linkedin]” size=”25″ tabindex=”‘, $context[’tabindex’]++, ‘” />
</td>
</tr>’;
]]></add>
</operation>
</file>
Ready!
you can download this Linkedin.com field mod for SMF here.