So now you have a hack and you want to make it available to other people. The question is, how do you do this? The license agreement prevents you from distributing whole templates, and anyway, you're only making small changes to the template so it's silly to get people to replace code that is unchanged.
The best way to distribute hacks is in the form of clear instructions that others can easily follow. There are many ways to do this but the following is an example of one way that is clear and straightforward.
MODIFICATION PM READ RECEIPT CHECKBOX Version 1.0.2 ----------------------------------------------------- Open TEMPLATE pm_newpm Find and DELETE/COMMENT OUT: else if (formname.dopreview != true) { <if condition="$show[‘trackpm']"> if (confirm("$vbphrase[request_receipt_for_message]")) { formname.receipt.value = 1; } </if> } Find and DELETE/COMMENT OUT: <input type="hidden" name="receipt" value="0" /> Find: <div> <label for="cb_parseurl"> <input type="checkbox" name="parseurl" value="1" id="cb_parseurl" tabindex="1" $checked[parseurl] /> $vbphrase[automatically_parse_links_in_text] </label> </div> Below code ADD: <div> <label for="cb_receipt"> <input type="checkbox" name="receipt" id="cb_receipt" value="1" /> Request Read Receipt? </label> </div> SAVE pm_newpm and CLOSE. Test modification. END OF MODIFICATION -------------------
With this hack we needed only to modify templates, but there are times when you need to document edits to settings or even to actual PHP files. Settings changes can be documented by specifying the menu navigation and the final setting change.
Admin CP -> Usergroups -> Usergroup Manager -> Edit Usergroup Set "Can Use Message Tracking" and "Can Deny Private Message Read Receipt Request" to "No".
The PHP file modification that we saw in Chapter 4 can also be documented in this way:
PAYPAL MODIFICATION Version 1.0.2 --------------------------------- Open includesfunctions_subscriptions.php Find: <input type="hidden" name="no_shipping" value="1" /> Replace with: <input type="hidden" name="no_shipping" value="0" /> SAVE and UPLOAD Test modification. END OF MODIFICATION -------------------
Here are a few tips that make code distribution easier for both you and the person following the instructions: