Seeing calls to analytics.tiktok.com in our DNN site - dotnetnuke

We have a DNN site and I noticed on our home page that the dev tools show an error with an events.js file that is trying to call "analytics.tiktok.com". It is being blocked. I don't know if this is purposeful and I've searched our DNN modules code but haven't found an such reference.
The other devs can confirm they haven't added such code. I've searched the code folders for a file named events.js but haven't found one. I'm aware that DNN has large portions of it that are data driven but I don't know what tables to query to see if there's code that has that URL.
Is anyone aware if DNN or kendo controls has an references to tiktok?

It is definitely not part of DNN.
Another place to look for these calls are the skin (theme) controls in use, or the default.aspx. Anyway, if no one is aware of this stuff, I would check if you have a security hole (old Telerik libraries, unsafe passwords in FTP accounts...)

I would start by looking at the location in which that is embedded into the source of your webpage. Depending on where it is, that might help you track down "where" it is coming from.
It could be coming from inside source for a module, in the content of a module, in module settings, in a container, in a skin/theme, etc.

Related

drupal site UI stopped working for reasons unknown

Am working on a drupal-7 site but it suddenly has stopped showing the correct theme and just shows a garbled UI.
have thought about it and cannot seem to locate the reason for this.
wanted to ask that if any suggestions can be given of this . secondly is there a way to refresh the drupal site (i.e. run the drupal site installation process again without re-installing/deleting any physical file/database).
hope to have made the question clear :)
Two common reasons.
The last thing you did broke it.
Someone hacked it.
Reinstall the exact same version of drupal in a new folder with a new empty database. If the only things you changed were the content (no PHP patches etc), then you should be able to simply switch databases. You could also diff the installations to see if any files were altered.
issue solved. problem came apparently from a module (custom made) which had function name same as used somewhere else on site.
thank you for time and suggestions

What is the expected collaboration workflow with Sencha Architect?

I started a trial of Sencha Architect, and the more I use it more questions come to my mind for its actual feasibility usage in a development environment, one of the bigger questions I have is
In an environment that you can't edit the individual files in different editors, how can multiple people collaborate in developing different parts of a site, for example
app/models|components|views/Model1.js <- In charge of developer one
app/models|components|views/Model2.js <- In charge of developer two.
In a regular environment you could use git, for example, to distribute each file but in architect, you are not expected to edit files manually (which sucks because features like profiles are not exposed in architect). If you do edit them manually, it will cause problems or it may overwrite your code back to whatever data is on the project file so I am wondering what is the proper, or expected collaboration workflow with Sencha.
Having read the above posts, I still can't believe that keeping Sencha
metadata files in code repository and generating ALL JavaScript from metadata is suitable for big projects.
The idea of Sencha Architect is to keep the code not in javascript files, but in JSON metadata, and whenever you need to edit a JavaScript code, you have to use IDE and edit metadata. Phil Strong said "We ask that you continue to use Architect as your editor and doing so with 20 engineers is perfectly safe using Git or SVN.". Of course this workflow is very profitable for Sencha, it forces 20 people to use a licensed Sencha Architect, because to change a single line of JavaScript code the developer must use Sencha Architect.
When two people edit the same file, IDE updates metadata. Then they check-in the file into a code repository, and one of them has to resolve conflicts, so the developer has to merge two metadata files, not JavaScript files.
The whole idea of not letting developers to edit JavaScript unless they use Sencha Architect is counter-productive, because the same person can be using his favorite IDE for both Java and JavaScript development, or Python and JavaScript. Doing both client and server programming in the same IDE is faster than switch between two IDE's. The reality of a big project is that you have multiple teams around the globe who work with different IDE's, you also may have a short-term project implemented by a contractor who also has his favorite IDE.
ExtJS is a well designed framework, you don't need SenchaArchitect to modify a single line of JavaScript code.
When coding in JavaScript, I save my JavaScript file and refresh browser, and see the changes immediately. Sencha Archtect adds and additional step, it requires you to publish
javascript (generate JavaScript from metadata), and the bigger the project is, the longer is delay. Often I have to modify JavaScript files in production, sometimes changing a single line fixes the problem, again, I have to use Sencha Architect to re-generate this single line from metadata.
I use Sencha Architect for quick prototyping only, then check-in generated files into code repository and continue to edit JavaScript manually. With this approach I can use a version control system to see the history of JavaScript. If I checked in JSON metadata into
a VCS, then I would not have the history of JavaScript, I would have the history of JSON metadata which is counterintuitive.
I think that having metadata for GUI form is OK, but the limitation that MVC controller level has also to be generated from metadata is not OK.
While I appreciate very much Sencha's effort in creating useful and full-featured dev environment I don't think Sencha Architect is quite ready for relatively big projects and teams of developers.
I original Architect software very useful for quick prototyping and designing complex UI structures, but then again - after you figure out the way your UI elements will lay down in JS file - often it's easier and faster to copy-paste existing JS code.
I don't think this is the answer you were looking for, I just wanted to share my thoughts.
When I had searched for this same topic, I had found that it is the metadata/ directory that is the important meat of the project, and that all of the components are separated out into their own metadata files. This, along with the root level project files, is probably the important part for version control. The app/ is regenerated on save and probably can be excluded from version control.
The main xds project file containers more general references and will probably change less often than the metadata components. But it would change when new components are created or project/app level settings are modified.
Ideally, if you just check in the root files and the metadata folder, it should just work.
Working in a team with source/version control is quite easy with Sencha Architect. An Architect project is all enclosed in a project directory. Inside it's made up of n parts
project file - consists of a small amount of data used by Architect to open and maintain your project. It's the single file you can double click to open it
metadata directory - consists of the files that describe all the pieces of your project. Each class (controller, view, model, store, resource) has it's information stored in it's own file.
app directory - consists of the src of the project you've created. A javascript file for each class.
other root files - an app.html and app.js which is the launchpad for your application and what get's run when you preview your application. This is also where your packager.json, app.json would go.
The point of me describing all of this is to show you that the files generated by Architect are pretty much identical to what you would have created in your favorite editor by hand. The only additional information is the metadata and the project file. The metadata is all JSON.
FOR NOW!!
We ask that you continue to use Architect as your editor and doing so with 20 engineers is perfectly safe using Git or SVN. When a dev makes a change it changes both the metadata and the app for those files.
I asked the same question to Aaron from Sencha in a private message. He suggested to check in the entire project structure including app and metadata.
It works, we did one flow in our team.

DNN List multiple documents on page

I am developing an intranet using DotNetNuke and would like know if anyone has come across a module for listing many files stored in a website folder.
I have many pages which need to list a lot of reference documents, and am happy with DNN's ability to upload them into the file manager, but am coming unstuck with regard to adding each file to the 'Documents' module one by one for each page on the site.
I have done heaps of searching on this and was wondering if anyone had come across the same problem.
Yes indeed. Check out Ventrian's file links module
Use the core DNN file component to make directories and upload files into those directories. Then use Ventrian File Links to drop that module onto a page on your DNN site. You can then tell it what directory to show files for and it will list them nicely on the site for you.
It's very slick. Ventrian is a yearly fee, but their Articles module and Photo Gallery module are also amazing and I use them in majority of my projects.
There's also the Document Library module in the commercial editions of DotNetNuke that would do the same thing, but also adds in moderation, versioning, tracking, and more.

DotNetNuke Module Packaging

Does anyone know of any simple, concise tutorials for packaging DotNetNuke modules for DotNetNuke 4 and DotNetNuke 5? Preferably something concerning DotNetNuke 5.4, since that's what I'm running.
The examples that I've seen all assume background knowledge, or they are about short-cuts to the existing process. I'm a beginner, so I need the simple basics.
Yeah, it's kind of a nightmare the first time.
I started here: Creating a DotNetNuke® Module - For Absolute Beginners! It's DNN 4.x, so a few of the conventions may have changed, but it will probably be close enough to get you going.
Creating a DNN Module and Understanding DNN Architectural Approach goes into more detail:
I suppose the important concept is: you're writing a WebControl using the MVC pattern. The DNN Module Wizard will create a "view" page for you, and you add code to suit.
there's some good resources here for info on packages:
http://www.dotnetnuke.com/Community/Blogs/tabid/825/EntryId/1140/Packaging-and-protecting-your-DotNetNuke%C2%AE-Module.aspx
by Michael Washington (mentioned above)
http://www.dotnetnuke.com/Development/Forge/ModuleReports/tabid/970/EntryId/453/DotNetNuke-4-3-Starter-Kit-and-Item-Templates.aspx
by Shaun Walker
Simple basics...
When you start with the DNN module template in Visual Studio there's a standard .dnn file there. this file must be modified to include all files needed to run the module (resx, images, dlls, ascx, .sqldataprovider) without any of the sourcecode files (.cs, .vb).
zip all of the files mentioned in the .dnn file up with the dnn file (all files in root of the zip) and submit it to the upload new module page (logged in as Host).
the zip is automatically extracted, the .dnn file is read and all files are placed in the appropriate places.
resources for creating packages:
http://www.codeproject.com/KB/dotnet/DnnModulePackager.aspx
http://www.mitchelsellers.com/blogs/articletype/articleview/articleid/200.aspx
by looking at these you can also further your understanding of package creation.
i'm using 4.9 currently so someone may want to correct me on changes that i'm unaware of.
Google for Michael Washington and / or Mitchel Sellers and they have excellent work on Module Development.
Mark Breen
Ireland
Chris Hammond has recently written two blog posts on dotnetnuke.com about packaging modules, you should really have a look that those, they are super, he tells you how to set up your environment and how to create a C#Template for your modules.
thanks
Mark
A good place to start is use the IFrame module. It's all code behind so no compile needed before deployment. Look in the dnn file to see where the files are copied to.
You might also want to look at https://github.com/dazinator/DnnPackager which is a NuGet package that when added to your module project, automates production of the install zip, and has other features

Can this be done by skinning?

I am working on DNN 4.09.03. I want to modify the look and feel of a links module. I know how to change the outer looks with containers, but I want achieve a mouseover effect for the links itself.
Looking closely it appears that the links are placed into a table datacell. I want to set the background of that cell to and image, and on mouseover swap it for another image. Can this be done with skinning?
If not, I need some assistance in extending/customising the links module source. I need to know how to set up the development environment to do this first. I have the DotNetNuke solution (with source code) working in VS2008. How do I integrate the source of the links module, so i can customise it (and rename - maybe mylinks)?
I don't think you can do this by containers. If you can do it by any chance, I bet doing it by modifying the code is easier. You have to remember that you might have problems upgrading the links module in future if you modify it.
Just add the Links module to DNN VS2008 solution as a web application. You can do whatever change you won't to do in it. And then use a nant script to just package it and copy to DNN/Install/Modules folder. And then hit the DNN installation URL:
http://<dnn_url>/Install/Install.aspx?mode=installresources
Alternatively you can write some post-build commands in VS2008 it self to copy stuff. Have a look at the existing modules and where each different part files of a module (.ascx, .dnn, .sqldataprovider) is stored in DNN after installation.
This is possible with some creative CSS and maybe even a little jQuery - i did a lot of this sort of thing for the Blog module without having to touch the core module -

Resources