+ Post New Thread
Results 1 to 7 of 7
Web Development Thread, EmailToWiki.pl in Coding and Web Development; Right trying to get this to work http://www.organicdesign.co.nz/Extension:EmailToWiki.pl But think line Code: content => "[[:Template:$wikiTemplate]]" is wrong as I get ...
  1. #1

    russdev's Avatar
    Join Date
    Jun 2005
    Location
    Leicestershire
    Posts
    6,924
    Thank Post
    709
    Thanked 551 Times in 366 Posts
    Blog Entries
    3
    Rep Power
    204

    EmailToWiki.pl

    Right trying to get this to work

    http://www.organicdesign.co.nz/Extension:EmailToWiki.pl

    But think line

    Code:
    content  => "[[:Template:$wikiTemplate]]"
    is wrong as I get wiki article created but the content is

    "[[:Template:Email]"

    Which is just a link to the template.

    I think need to add to bit where it says: -

    logAdd "Processing email from $from to $to, subject: $subject";
    Code:
    $del       =  $deleteProcessed;
    		$time      =  localtime();
    		($title)   =  split /@/,$to;
    		$title     =~ s/\&([a-f0-9]{2})/pack('C',hex($1))/gise;
    		($subject) =  grep /^subject:/i,@$text;
    		$subject   =~ s/^.+?:\s*(.*?)(\r?\n)*/$1/
    So anyideas people.

  2. #2
    contink's Avatar
    Join Date
    Jul 2006
    Location
    South Yorkshire
    Posts
    3,791
    Thank Post
    303
    Thanked 327 Times in 233 Posts
    Rep Power
    118
    Think I've got it...

    Code:
    # Post the data using Extension:SimpleForms to prepend/append/replace/create content
    If you don't have the SimpleForms extension installed that may explain why it's not working properly.

  3. #3

    russdev's Avatar
    Join Date
    Jun 2005
    Location
    Leicestershire
    Posts
    6,924
    Thank Post
    709
    Thanked 551 Times in 366 Posts
    Blog Entries
    3
    Rep Power
    204
    No got that installed and working.

    Russell

  4. #4
    contink's Avatar
    Join Date
    Jul 2006
    Location
    South Yorkshire
    Posts
    3,791
    Thank Post
    303
    Thanked 327 Times in 233 Posts
    Rep Power
    118
    Ok... only other thing I can think of is that the template is missing.

  5. #5

    Join Date
    Nov 2007
    Location
    Preston
    Posts
    98
    Thank Post
    2
    Thanked 4 Times in 4 Posts
    Rep Power
    14
    the script doesnt actually define $wikiTemplate at all, if they used lexical variables the script would fail to execute.

    [[:Template:$wikiTemplate]]

    looks as though its some kind of bbs code to me, never played with mediawiki though.

    install wireshark and sniff the post requests sent to your wiki from the script and post here.

  6. #6

    russdev's Avatar
    Join Date
    Jun 2005
    Location
    Leicestershire
    Posts
    6,924
    Thank Post
    709
    Thanked 551 Times in 366 Posts
    Blog Entries
    3
    Rep Power
    204
    Yes problem as I can see it define template but codes pass no variables to the template or am I being daft?

    Russ

  7. #7

    Join Date
    Nov 2007
    Location
    Preston
    Posts
    98
    Thank Post
    2
    Thanked 4 Times in 4 Posts
    Rep Power
    14
    did you try this yet?

    content => "$text"

SHARE:
+ Post New Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •