[Snippet] QR Post Links

Archive of my first mod

[Snippet] QR Post Links

Postby 4seven » Sun 30. May 2010, 20:31 | Userzeit: +1.00 / So 30. Mai 2010, 21:31

QR Post Links

Snippet-Title: QR Post Links
Snippet-Version: 0.0.1
Snippet-Autor: 4seven

Credits: Y.Swetake for QRcode v. 0.50i

Request by: hinix
Request Topic: http://www.phpbb.com/community/viewtopi ... #p12667325

Description: This Mod shows QR Links in Posts

phpBB-Version: phpBB 3.0.x
phpBB-Sprachen: mutlilingual
phpBB-Styles: prosilver, subsilver2

Features: This Mod shows QR Links in Posts, so u can scan this directly to your Mobile Devices

Requirements: GD 2+ / PHP 4/5

Topic Demo: http://4seven.bplaced.net/phpbb3/viewtopic.php?f=7&t=371
Posting Demo: http://4seven.bplaced.net/phpbb3/posting.ph ... &f=7&t=371 ( click on [qr_link] )


4seven wrote:
Image

means:
Code: Select all
http://www.phpbb.com/community/viewtopic.php?f=72&t=2079085&p=12796961#p12796961


copy img-adress or download img and enter here to check: http://zxing.org/w/decode.jspx



Instruction

download package
QR_Post_Links_v_0_0_1.zip
(1017.7 KiB) Downloaded 362 times

copy

root/qr/*.* > qr/*.*

open

styles/xxxxxx/template/editor.js

find

Code: Select all
   // Open tag
   insert_text(bbopen + bbclose);   


replace with

Code: Select all
        // qr_link bbcode
        if (bbopen == '[qr_link]')
        {
            var Error = '';
            var QR = prompt('Insert a Link to generate QR (with http://)' , '');
            if (!QR) {
            Error = "U don't enter anything";
            }
            if (Error) {
            alert("Error: "+Error);
            return;
            }
            if (QR) {                
                QR 
= escape(QR);
                QR = encodeURI(QR);
                insert_text('[img]http://4seven.bplaced.de/phpbb3/qr/php/qr_img.php?e=L&s=4&t=J&d=' + QR + '[/img]');
            }
            else {
                return;
            }
        }
        
    else
{
    // Open tag
   insert_text(bbopen + bbclose);}    


Note: replace

Code: Select all
http://4seven.bplaced.de/phpbb3/

to your forum root folder


open

styles/prosilver/template/posting_buttons.html

find

Code: Select all
    <!-- END custom_tags --> 


after add

Code: Select all
    <input type="button" class="button2" name="qr_link" value="qr_link" onclick="bbfontstyle('[qr_link]','[/qr_link]');this.form.addbbcode9999;" title="Click to start Wizard" /> 


open

styles/subsilver2/template/posting_buttons.html

find

Code: Select all
        <!-- END custom_tags --> 


after add

Code: Select all
                    <input type="button" class="btnbbcode" name="qr_link" value="qr_link" onclick="bbfontstyle('[qr_link]','[/qr_link]');this.form.addbbcode9999;" title="Click to start Wizard" /> 


Clear all Board-, Style- and Browser-Caches
User avatar
4seven
Administrator
 
Posts: 427
 
Last 3 Topics:
Tabmenu Test
[Snippet] Avatar Ev...
[DEV] Zero and X-P...
 
Joined:
Sun 13. Jan 2008, 23:44
 
Letzter Login:
Mon 1. Aug 2022, 16:40
 
Posted:
Sun 30. May 2010, 20:31 +1.00
Userzeit: So 30. Mai 2010, 21:31

Return to BBCodeBox3



Who is online

Users browsing this forum: No registered users and 0 guests

cron