Gets the url for a module
@param BackendModule $module The module
@param array $args
@return string
172552
static function ModuleUrl(BackendModule $module, array $args = array())
    {
        $allArgs = array('module'=> ClassFinder::ModuleType($module)) + $args;
        return 'index.php?' . http_build_query($allArgs);
    }
507737
public static function getModule($module) {
        $info = null;
        if (isset (self::$modules [ $module ])) {
            return self::$modules [ $module ];
        }

        return $info;
    }
181543
protected function urlRoute($module, $controller, $params): string
    {
        $url = $this->getBaseUrl();

        if (empty($params) && $controller === self::DEFAULT_CONTROLLER) {
            if ($module === self::DEFAULT_MODULE) {
                return $url;
            }
            return $url . $module;
        }

        $url .= $module . '/' . $controller;
        $getParams = [];
        foreach ($params as $key => $value) {
            // sub-array as GET params
            if (\is_array($value)) {
                $getParams[$key] = $value;
                continue;
            }
            $url .= '/' . urlencode((string)$key) . '/' . urlencode((string)$value);
        }
        if (!empty($getParams)) {
            $url .= '?' . http_build_query($getParams);
        }
        return $url;
    }
173381
public static function getModuleInfo($module=null, $parent=null)
	{
		define('DS', DIRECTORY_SEPARATOR);
		if($module != null) {
			$modulePath = Yii::getPathOfAlias('application.modules.'.$module);
			$moduleFile = $module.'.yaml';
			if($parent != null) {
				$modulePath = Yii::getPathOfAlias('application.modules.'.$parent);
				$module = $parent.'-'.$module;
				$moduleFile = $module.'.yaml';
			}
			$YMLPath = $modulePath.'/'.$moduleFile;

			if(!file_exists($YMLPath)) {
				$modulePath = Yii::getPathOfAlias('ommu.'.$module);
				if($parent != null) {
					$modulePath = Yii::getPathOfAlias('ommu.'.$parent);
				}
				$YMLPath = $modulePath.'/'.$moduleFile;
			}
			
		} else
			$YMLPath = Yii::getPathOfAlias('application.libraries.core').DS.'core.yaml';
			
		if(file_exists($YMLPath)) {
			$moduleInfo = self::getArrayFromYML($YMLPath);
			
			return $moduleInfo;
			
		} else
			return false;
	}
1217942
def get_asset_url(module: str, path: str) -> str:
    
    return '{}/{}/{}'.format(
        settings.STATIC_URL.rstrip('/'),
        module,
        path.lstrip('/'),
    )
799847
def get_annotation_url(module, version):
    
    module = module.strip('/')

    return '{module}/{name}'.format(
        module=get_annotation_module_url(module),
        name=get_annotation_file_name(module, version),
    )
156123
public function url( array $args = []) {
		$url = get_term_link( $this->term );
		if ( $args ) {
			$url = add_query_arg( $args, $url );
		}

		return $url;
	}
455996
public function getEditUrl($backend = false)
    {
        $url = [
            'action'     => 'edit',
            'controller' => 'Users',
            'plugin'     => 'Community'
        ];

        if ($backend) {
            $url['prefix'] = 'admin';
            $url[] = $this->id;
        }

        return Router::url($url);
    }
1162334
public function getModuleDir($module, $dir)
    {
        return $this->jsDir.DIRECTORY_SEPARATOR.$dir.DIRECTORY_SEPARATOR.$this->getModuleFileName($module);
    }
1247224
public function getModule ($module)
	{
		
		// Load modules
		
		$this->getModules ();
		
		// Loop through the modules
		
		foreach ($this->modules as $obj)
		{
			
			// If the module names match and the class exists
			
			if (strtolower ($obj->get ('name')) == $module && class_exists ($obj->getModuleClass ()))
			{
				
				// Return the module
				
				return $obj;
				
			}
			
		}
		
		// Return FALSE
		
		return FALSE;
		
	}
1345998
public function getModulesPath()
    {
        $paths = array();
        foreach ($this->getLoadedModules(true) as $module) {
            $paths[$module->getName()] = $module->getPath();
        }

        return $paths;
    }
446082
protected function BackLink()
    {
        $params = array('site'=>$this->page->GetSite()->GetID());
        $params['selected'] = $this->page->GetID();
        return BackendRouter::ModuleUrl(new PageTree(), $params);
    }
101310
protected function url($args) {
		$target = $args['target'];
		$options = isset($args['options'])? $args['options'] : array();
		if (($volume = $this->volume($target)) != false) {
			$url = $volume->getContentUrl($target, $options);
			return $url ? array('url' => $url) : array();
		}
		return array();
	}
4240
public function getModuleName()
    {
        $module = $this->argument('module') ?: app('modules')->getUsedNow();

        $module = app('modules')->findOrFail($module);

        return $module->getStudlyName();
    }
863953
public static function getRoutesFilename($module, $type)
    {
        $class = new ReflectionClass($module);
        $dirname = dirname($class->getFileName());
        $baseFileName = sprintf(BaseModule::$patternRoutesFilename, $type);
        $routesSubdir = $dirname . DIRECTORY_SEPARATOR . static::$configsSubdir;
        $file = $routesSubdir . '/' . $baseFileName;
        if (is_file($file)) {
            return $file;
        }
        if ($module instanceof self) {
            throw new Exception("Routes list file '{$baseFileName}' not found in config(s) folder(s) for module " . $module->className());
        } else {
            return false;
        }
    }
506071
private function createDropDownItemSubUrl(array $args): string
    {
        list($url, $text, $place, $id, $class) = $this->getLinkInformation($args);
        $output = '<a class="dropdown-item dropdown-toggle';
        $output = !empty($class) ? $output . ' ' . $class . '"' : $output . '"';
        if (!empty($id)) $output .= ' id="' . $id . '"';
        $output .= ' href="' . BASE_URL . $url . '">' . $text . '</a>';
        return $output;
    }
505616
public function getModuleMarkup($module, $args)
    {
        $templatePath = $module->template();

        // Get template for legacy modules
        if (!$templatePath) {
            $templatePath = \Modularity\Helper\Wp::getTemplate($module->post_type, 'module', false);
        }

        if (!$templatePath) {
            return false;
        }

        $moduleMarkup = '';
        if (preg_match('/.blade.php$/i', $templatePath)) {
            $moduleMarkup = $this->loadBladeTemplate($templatePath, $module, $args);
        } else {
            $moduleMarkup = $this->loadTemplate($templatePath, $module, $args);
        }

        if (empty($moduleMarkup)) {
            return;
        }

        $classes = array(
            'modularity-' . $module->post_type,
            'modularity-' . $module->post_type . '-' . $module->ID
        );

        //Hide module if preview
        if (is_preview() && $module->hidden) {
            $classes[] = 'modularity-preview-hidden';
        }

        //Add selected scope class
        if (isset($module->data['meta']) && isset($module->data['meta']['module_css_scope']) && is_array($module->data['meta']['module_css_scope'])) {
            if (!empty($module->data['meta']['module_css_scope'][0])) {
                $classes[] = $module->data['meta']['module_css_scope'][0];
            }
        }

        $beforeModule = '';
        $moduleEdit = '';
        if (!(isset($args['edit_module']) && $args['edit_module'] === false) && current_user_can('edit_module', $module->ID)) {
            $moduleEdit = '<div class="modularity-edit-module"><a href="' . admin_url('post.php?post=' . $module->ID . '&action=edit&is_thickbox=true&is_inline=true') . '">' . __('Edit module', 'modularity') . ': ' . $module->data['post_type_name'] .  '</a></div>';
        }

        if (isset($module->columnWidth) && !empty($module->columnWidth)) {
            $beforeWidget = $module->columnWidth;

            $classes[] = $beforeWidget;

            $beforeModule = apply_filters('Modularity/Display/BeforeModule', '<div class="' . implode(' ', $classes) . '">', $args, $module->post_type, $module->ID);
        } elseif (isset($args['before_widget'])) {
            $beforeWidget = str_replace('%1$s', $module->post_type . '-' . $module->ID, $args['before_widget']);
            $beforeWidget = str_replace('%2$s', implode(' ', $classes), $beforeWidget);
            $beforeModule = apply_filters('Modularity/Display/BeforeModule', $beforeWidget, $args, $module->post_type, $module->ID);
        }

        $moduleMarkup = $beforeModule . $moduleEdit . $moduleMarkup;
        return $moduleMarkup;
    }