Dynamic Content Include
Added by Thomas Curtis almost 14 years ago
Hi all. I am new to Redmine and indeed RoR. Currently my company uses Trac for what I want to use Redmine for. Redmine is just so clean in comparison. Anyway the only thing currently holding me back is a replacement for a macro I have in Trac. It allows me to do [[Include(http://reports.localhost:5081/currentData.php)]] and it gets the HTML markup and displays it in the Wiki area. I am considering writing a new plugin, which would require I learn RoR (not opposed to this), or asking all of you if I am possibly missing something in the forums, or wiki, or on google. Each of which I have spent hours pouring though. I would appreciate advice or help. A new tab is something I am considering as well. Anyway I did see an iFrame plugin but that means I would need to implement another layer of authentication. Currently the Trac plugin does its retrieval server side so the markup only travels via the Trac server which is HTTPs secured. Thanks to all of you and any of you that can provide assistance.
About your application's environment
Ruby version 1.8.7 (x86_64-linux)
RubyGems version 1.3.7
Rack version 1.0
Rails version 2.3.5
Active Record version 2.3.5
Active Resource version 2.3.5
Action Mailer version 2.3.5
Active Support version 2.3.5
Application root /opt/redmine-1.0
Environment production
Database adapter mysql
Database schema version 20100819172912
Replies (4)
RE: Dynamic Content Include
-
Added by Felix Schäfer almost 14 years ago
You can extend the wiki markup with a macro and do all that from a plugin, so that is not something impossible. Fetching a remote URI as a string and rendering said string as the result of the macro shouldn't be too hard either.
RE: Dynamic Content Include
-
Added by Thomas Curtis almost 14 years ago
Okay. I appreciate the response. I don't mean to sound like one of those whiney 'do this for me' forum jerks but might you point me in the direction of a few resources that might help me get this coded up and running. Thanks again.
RE: Dynamic Content Include
-
Added by Felix Schäfer almost 14 years ago
Mmh, can't remember where the docs for the wiki stuff was, I had looked for it already but found nothing. I think reading through the (first steps of the) plugin tutorial to get a feeling of how a plugin works and then having a look at any wiki-extending plugin on the PluginList should get you going, I'll let you google for "ruby read string from URL", but something like:
require 'open-uri'
my_string = open('http://yourhost').read
Should work OOTB to get the string from your URL (open-uri is part of the core libs IIRC).
RE: Dynamic Content Include
-
Added by Thomas Curtis almost 14 years ago
That's cool. I can google with the best of em. I just need a starting point. As a php developer myself it shouldn't take long to get moving once I find that foothold. Thanks.