namespaces,typo3,typo3-6.2.x , TYPO3-Upgrade 4.5 to 6.2: namespaces

TYPO3-Upgrade 4.5 to 6.2: namespaces


Tag: namespaces,typo3,typo3-6.2.x

I'm updating an old TYPO3 to latest verison 6.2.12. As I do so I replace deprecated classes with the proper namespaces. E.g. t3lib_div to \TYPO3\CMS\Core\Utility\GeneralUtility or t3lib_extmgm to \TYPO3\CMS\Core\Utility\ExtensionManagementUtility.

But I cant find the proper namespaced class for t3lib_svbase. Any suggestions?


And I absolutely have no clue what I need to do with the new xclassed include.

//old XCLASS
if (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['ext/foo_myfancyextension/sv1/class.tx_foomyfancyextension_sv1.php'])   {

It should look something like this:

//new XCLASS
$GLOBALS['TYPO3_CONF_VARS']['SYS']['Objects']['TYPO3\\CMS\\Frontend\\ContentObject\\FluidTemplateContentObject'] = array(
    'className' => 'Enet\\FxLibrary\\Xclass\\FluidTemplateContentObject',

But where is the path to my extension and the class itself?


To use the new XLASS feature, you need to provide a proper autoloading, by either sticking to the convention or by creating an ext_autoload.php file.


htaccess and authentication for multiple domains

I am running a mutlisite TYPO3-Site. For the pre-live process, I want to add a htaccess with a htpasswd for 3 / 4 sites. How can I configure the htaccess-file to trigger the authentication only for specific urls? For example: shouldn't get a password-protection, while should. Both sites...

Typoscript add class to the first element using stdWrap

I have a custom requirement to display an image slider using TypoScript. The images are taken from default tt_content image content element. I've added the following TypoScript code to implement this; lib.homeslider = COA lib.homeslider { 10 = CONTENT 10 { table = tt_content select { where = colPos =...

Where are TYPO3 constants from constant editor stored?

In Typo3 Backend -> Template -> Constants there is a constant editor. Where does TYPO3 saving the constants? Tried an fgrep -ri for an existing pattern, in case of saving to filesystem - no matches. Tried an MySQL search for an existing pattern, in case of saving to DB -...

Mediawiki custom namespaces id change

I am currently working on an internal Mediawiki and we are using a lot of custom written extensions. Because we did no know better, defined custom namespaces for our own extensions and articles with an id that is smaller than 3000. For example: define('NS_bla', 1100); $wgExtraNamespaces[NS_bla] = "bla"; define('NS_bla_TALK', 1101);...

how to use class of other project in a solution (internal)? [duplicate]

This question already has an answer here: How to use a Class from one C# project with another C# project 7 answers Environment : In C#, I have a solution with many project. They were added with *.csproj files. Problem : In a project, you can use classes of...

How to get Query object to felogin repository?

i need Query object of TYPO3\CMS\Felogin\Controller\FrontendLoginController in my extention repository so i can create my own query conditions.

Hide typo3 content elements for specific user(groups)

I want to "hide/deactivate" the table element for specific users/usergroups in the typo3 BE. Or to be more clear: I want to ONLY allow it to ONE specific user (admin). How can i do that? NOTE: At the moment the table element is deactivated in the global TS-config via tt_content...

C++: Does inheriting from a class bring it into the namespace?

Here's some contrived example code: template<typename T> void Do(T arg) { (void)arg->b; } namespace A { struct Foo { int a; }; } namespace B { struct Foo { int b; }; struct Bar : A::Foo { void Blah() { Do((Foo *)0); } }; } Which when compiled with gcc...

How to use namespace System; in MFC application with VC++

help me,am new, I want to use some features(i don't know the specific word to use) present in System namespace, but when i try to add it to my project by "using namespace System",i want this to use SQLCLIENT ,i saw below link giving answer but dont have a clue...

Python class and global vs local variables [duplicate]

This question already has an answer here: Python class scoping rules 2 answers I have a problem understanding what is happening with the outcome of the following pieces of code: my_str = "outside func" def func(): my_str = "inside func" class C(): print(my_str) print((lambda:my_str)()) my_str = "inside C" print(my_str)...

Python: is there a way to use “unimported” objects in function definitions?

I'm modifying a simple recursive function to draw a dragon curve using turtle: def draw_dragon(t, order, size, L=turtle.left, R=turtle.right): """ Draw a dragon curve """ if not order: t.forward(size) return size /= 1.41421 t.R(45) draw_dragon(t, order-1, size, L, R) t.L(90) draw_dragon(t, order-1, size, R, L) t.R(45) if __name__=="__main__": import turtle...

how to solve the type and namespace could not be found

I am trying to make a cross platform application using MONO. i developed the project into c#(windows) and I want to run that project into Linux. For that purpose i am using MONO.But when i am running my project then I am getting error that the type and namespace could...

KDB+ / Q Accessing root namespace from namespace

how can I access functions/variables in the root namespace once I jumped into another namespace. Example like this: q)\d .cfg q)domIV:1000 q)\d . q)n:1000 And then later on I know how to access the variable domIV from the other namespace, but I dont know how to access the variable n...

friendship and namespace issue

I'm having troubles with friendship between a class of a namespace and a function as below: How to tell that the friend function is outside of the namespace? Thanks namespace NS { class Class { public: Class(); virtual ~Class(); private: void Foo(); friend void Bar(Class&); }; } void Bar(NS::Class& c)...

Leiningen REPL not autoloading project.core namespace [duplicate]

This question already has an answer here: how to load ns by default when starting repl 2 answers I'm new to Clojure so this could very well be an easy question. I'm having an issue with the REPL while using Leiningen. Previously, I had created an app project while...

Silex namespace : class MainController does not exist

I try to use Silex Framework, but i have a problem with namespaces I think. when I instanciate my class MainController i have the following error : Class "MainController" does not exist here the namespace declaration in my MainController.php : namespace App\Controllers; use Silex\Application; class MainController implements \Silex\ControllerProviderInterface { .......

How to assign variable in fluid?

I want viewhelper that can be helpful to assign variable in fluid, I dont want variable to be passed from controller.

Rails: Rendering a template in a different namespace

How can I render an action of a controller which is in a different namespace? For example, if I have a login controller in a Webapp namespace Webapp::LoginController and I want to render the index action (not a partial!) in an events controller in the API namespace API::EventsController if the...

How to Move a class to another dll and change the namespace without altering the method usage

I have a dll where I have one class which logs to a "channel", another Program listens to the "channel" and writes the logs to the screen. The problem with the dll is that its grown over time and now there are many dependecies in it. I want to remove...

The name 'Thread' does not exist in the current context

When I put this code Thread.Sleep(2000); it gives me the error: The name 'Thread' does not exist in the current context`. I already included the namespace using System.Threading;. See System.Threading.Thread.Sleep() on MSDN....

R cannot load package forecast due to namespace error

I tried installing all the dependant packages and also tried another repo source as recommended in another post here. R version 3.2.0 x64 install.packages("fracdiff") install.packages("Rcpp") install.packages("RcppArmadillo") install.packages("colorspace") install.packages("forecast", dep=T) install.packages("forecast", repos=c(""),dep=T) library("forecast") then I get Loading required package: zoo Attaching package: ‘zoo’ The following objects are masked from ‘package:base’: as.Date,...

How to use Hook “processDatamap_postProcFieldArray” in TYPO3 6.x

Use case: When saving an object (in backend, maybe in frontend too later) I want to manipulate values before saving to database. Problem: The file seems to get included (shows an error on save if I choose a wrong file path) but the function does not seem to be executed...

Are namespaces in PHP “inherited”?

EDIT: Yes the problem was using \ at the beginning of the use statement. As M1ke pointed out, use goes from the root element. Original post I think is a PHP question but it may be Drupal. I'm working on a headless Drupal project where is using a class (which...

Javascript variable is set in one function, but undefined in another function

I have the following Javascript, eventManager: { $musicGenres : null, // $musicGenres is the selector for a div-container of inputs musicGenres : [], // Functions handle : function(selectors) { selectors = (typeof selectors === 'undefined') ? { 'musicGenres' : '#musicGenres' } : selectors; // selectors default values... this.$musicGenres = $(selectors['musicGenres']);...

How to get typo3 settings in the utility files?

plugin.tx_xxx { setting { storagePid = 23 } } I want this typo3 settings in utility file. Please help me....

how to add new account in outlook with Name Space C#2003

public void sendEMailThroughOUTLOOK() { if(MessageBox.Show(PublicFunction.L_Get_Msg("msg",28),"MessageBox",MessageBoxButtons.OKCancel)== DialogResult.OK) { try { // Create the Outlook application. Outlook.Application oApp = new Outlook.Application(); //set default account send mail Outlook.Account account = GetAccountForEmailAddress(oApp,"[email protected]"); // Create a new mail item. Outlook.MailItem oMsg = (Outlook.MailItem)oApp.CreateItem(Outlook.OlItemType.olMailItem); // Set HTMLBody. //oMsg.HTMLBody= "<html> <p...

autoloading nested classes with composer

I have created a very basic validator class. My base code is in a my src/ folder, which gets autoloader with "kevdotbadger\\Validator\\": "src/" this works fine, so that when I instantiate a new "kevdotbadger\Validator\ Validator is gives me src/Validator.php My Validator.php class then loads a bunch of sub-classes in my...

Why is ::class appended to PHP class in Laravel 5.1

In Laravel 5.0 code like this is used for names-pacing/loading classes: 'providers' => [ /* * Laravel Framework Service Providers... */ 'Illuminate\Foundation\Providers\ArtisanServiceProvider', 'Illuminate\Auth\AuthServiceProvider', 'Illuminate\Broadcasting\BroadcastServiceProvider', 'Illuminate\Bus\BusServiceProvider', ] However, am seeing this in Laravel 5.1 'providers' => [ /* * Laravel Framework Service Providers... */ Illuminate\Foundation\Providers\ArtisanServiceProvider::class, Illuminate\Auth\AuthServiceProvider::class,...

c++ operator overloading and associated namespace

The following simplified example compiles in gcc and Visual Studio, but fails in clang !? namespace N { struct A {}; template <typename T> double operator+ (T a, double d) {return d;} template <typename T> double operator+ (double d, T a) {return d;} } void test() { N::A a; double...

Namespace for (DDD) entities cutting across domains

I have a couple of business-related domains like Purchase, Marketing and Economy. Having the models arranged into a namespace* for each domain would be nice, but there are some entities cutting across domains, like an Item. How to organize those cross-cutting objects? * = As in C#/Java/Python namespaces....

XML, XSL namespaces

I'm new to XML especially namespaces. I made all the documents and everything seems to work fine, but I don't know whether I'm really using namespaces (which is requirement). Except that my html file are not valid because off this: "Attribute xmlns:xsi not allowed here." and "Attribute xmlns:xslformatting not allowed...

Fatal error: Class 'Psr\Log\AbstractLogger' not found in Logger.php on line 30

I'm getting this error: Fatal error: Class 'Psr\Log\AbstractLogger' not found in /var/www/html/rackspace/vendor/rackspace/php-opencloud/lib/OpenCloud/Common/Log/Logger.php on line 30 This is my Logger.php file <?php /** * Copyright 2012-2014 Rackspace US, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with...

Replace URLs in Typo3 DB

So I have a Site created with Typo3. I also have a domain which is linked to the folder of the Typo3 Installation. I created a Subdomain and linked it to the same folder and used the Main Domain for something else. But now everything on the Subdomain still...

Namespace keyword in TypeScript

Trying to find out what does namespace keyword mean in TypeScript? Here's some reshuffle they've done recently to use namespace instead of module: In the absence of namespace spec, it looks like a rather pointless rename to make the language look C#-like. Or is there an obscure little difference...

Laravel Interfaces

I used the following tutorial to get an idea about interfaces: But I wanted to change the directory of where I am putting my interfaces to "App/Models/Interfaces". And so I did. But now I cannot get it to work anymore. Here is my code: Routes.php App::bind('CarInterface', 'Subaru'); Route::get('subaru', function()...

PHP require files when use namespace

I'm new to PHP namespace. and there is a problem when I use auto-load. ROOT/Application/Instance.php <?php namespace Application; class Instance { public static $_database; public function __construct() { self::$_database = new \Application\Module\Database(); } public static function database() { return self::$_database; } public static function ID(){ return md5(uniqid(mt_rand(), TRUE) . mt_rand()...

Reference C# type within XML schema?

Is it possible to reference types within a C# project in an XML Schema file? For validation and intelli-sense I mean... Lets say I have the following: namespace Example { class myType { int test = 0; } } How would I reference the Example namespace within the schema file...

How do I access DbContext.Entry Method (TEntity) in my generic repository class?

This should be really obvious but for some reason I can't figure it out. So in my generic repository class I have an update method to update an entity: public void Update<TEntity>(TEntity entity) where TEntity : class, IBusinessEntity { try { if (entity == null) { throw new ArgumentNullException("entity"); }...

C# Obtaining Namespace Based on CSProj settings

Is there a way to obtain the .csproj Default Namespace and Visual Studios understanding it without using preprocessor directives? For example: CS Project 1 has a Default Namespace of SomeCompany.ProductA CS Project 2 has a Default Namesapce of SomeCompany.ProductB CS Project 1 has a cs file that exists in BaseClasses/MySpecialBase.cs...

Get namespace of unqualified class name

Consider the following PHP code namespace foo\bar; class MyClass {} namespace xyz; use foo\bar\MyClass; class OtherClass {} $a = new MyClass(); $b = new OtherClass(); $a is an instance of \foo\bar\MyClass, while $b is an instance of \xyz\OtherClass. These fully qualified class names, I can get by calling get_class($a) and...

Should one forward declare classes from a namespaced library?

I'm designing a C++ library that will be placed inside a namespace. If the users of my library only need a forward declaration of one of my classes and since you can't do forward declarations of things inside a namespace, e.g. class ns_name::class_name;, should I tell them to include the...

Disabling default namespaces

Rust seems to use some namespaces by default. For example, I don't have to use std::string::String and can simply type String. How can I define my own struct String without clashing with std::string::String? And where can I find a list of the namespaces that are included by default?

System.ComponentModel.DataAnnotations.Schema namespace conflict

I am using MVC 4, .net 4, and Entity Framework 6. My projects are building on my dev machine which has Visual Studio 2010 installed but on my build server I get a namespace conflict... The type 'System.ComponentModel.DataAnnotations.Schema.DatabaseGeneratedAttribute' exists in both 'd:\Projects\tools\Apps\LAMS\packages\EntityFramework.6.0.2\lib\net40\EntityFramework.dll' and 'c:\Windows\Microsoft.NET\assembly\GAC_MSIL\System.ComponentModel.DataAnnotations\v4.0_4.0.0.0__31bf3856ad364e35\System.ComponentModel.DataAnnotations.dll' I'm unsure...

TYPO3-Upgrade 4.5 to 6.2: namespaces

I'm updating an old TYPO3 to latest verison 6.2.12. As I do so I replace deprecated classes with the proper namespaces. E.g. t3lib_div to \TYPO3\CMS\Core\Utility\GeneralUtility or t3lib_extmgm to \TYPO3\CMS\Core\Utility\ExtensionManagementUtility. But I cant find the proper namespaced class for t3lib_svbase. Any suggestions? . And I absolutely have no clue what I...

Deleting namespace in Socket IO

This question has been asked before here, but I've implemented the answer and the problem has persisted. I'm working in typescript and I have a Room class that encapsulates a namespace (among other things), and a RoomManager class that maintains a list of rooms. I recently added functionality where a...

Typo3 6.2: “Could not find a suitable type converter for ”String“ ” exeption after update

Typo3 was from a very old version updated to Typo3 6.2. The most things are working now, but I have one own written extension that give me the following error: Core: Exception handler (WEB): Uncaught TYPO3 Exception: #1297759968: Exception while property mapping at property path "":Could not find a suitable...

How to follow DRY principles in different namespaces Rails 4.2?

Basically I've developed an app which has two namespaces: admin, api and the public one (simply resources :users for instance). All works fine, however I'm repeating myself quite a bit as some of the controllers in api for instance could easily be used in admin. How can I DRY my...

Get rid of Visual Studio Namespace error message

this is unfortunately a very beginner question: I am doing the very simple WPF tutorials and I am stuck on a namespace problem. I want to do a simple hierarchical treeview binding on a custom object according to the tutorial. I put the object into a custom namespace "MyNameSpace" and...

C# : Why is First namespace redundant?

This is a little spooky. I'm thinking there must be a setting somewhere that explains why this is happening. In our solution there are about 50 different projects. For the most part, the libraries start with the namespace OurCompany. We have OurComany.This.That and OurCompany.Foo.Bar... etc. There is a namespace/class clash...